This content originally appeared on DEV Community and was authored by hema latha
public static void main(String[] a
rgs) {
// TODO Auto-generated method stub
String word = "Chennai 600042";
for (int i = 0; i<word.length();i++ )
{
if(word.charAt(i)>='0')
if(word.charAt (i)<='9')
System.out.print(word.charAt(i));
}
}
out put 600042
This content originally appeared on DEV Community and was authored by hema latha
Print
Share
Comment
Cite
Upload
Translate
Updates
There are no updates yet.
Click the Upload button above to add an update.

APA
MLA
hema latha | Sciencx (2025-03-02T13:12:49+00:00) String with no. Retrieved from https://www.scien.cx/2025/03/02/string-with-no/
" » String with no." hema latha | Sciencx - Sunday March 2, 2025, https://www.scien.cx/2025/03/02/string-with-no/
HARVARDhema latha | Sciencx Sunday March 2, 2025 » String with no., viewed ,<https://www.scien.cx/2025/03/02/string-with-no/>
VANCOUVERhema latha | Sciencx - » String with no. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2025/03/02/string-with-no/
CHICAGO" » String with no." hema latha | Sciencx - Accessed . https://www.scien.cx/2025/03/02/string-with-no/
IEEE" » String with no." hema latha | Sciencx [Online]. Available: https://www.scien.cx/2025/03/02/string-with-no/. [Accessed: ]
rf:citation » String with no | hema latha | Sciencx | https://www.scien.cx/2025/03/02/string-with-no/ |
Please log in to upload a file.
There are no updates yet.
Click the Upload button above to add an update.