"Sun Certified Java Programmer" This is one String , we need
to print SCJP, write the java code dynamically? pls reply
this questions
Answer Posted / sreekanth madamanchi
public class Sample {
public static void main(String args[]) {
String str = "Sun Certified Java Programmer";
String str2 = null;
for(int i=0;i<str.length();i++)
{
char c = str.charAt(i);
if(Character.isUpperCase(c))
{
if(str2 == null || str2 == "")
str2 = ""+str.charAt(i);
else
str2 = str2+str.charAt(i);
}
}
System.out.println("Result="+str2);
}
}
Is This Answer Correct ? | 10 Yes | 2 No |
Post New Answer View All Answers
Hi we have an urgent requirement for Java/J2ee technical lead position & also looking for "Java Guidewire claimcentre" experienced professional for Bangalore location if interested can reach srisanh@gmail.com
What are the interfaces in java collections? : java collections
What are maps interfaces in the java collections? : java collections
Which sorting algorithm is used by collections.sort() in java ?
What are the different types of classes implemented in the set interfaces? : java collections
What are the types of the main implementing classes in the map interfaces? : java collections
Which java collection class can be used to maintain the entries in the order in which they were last accessed?
What are the considerations to be made in case of loops in java ?
Hi Friends, i have searched in google but not clear. can you give bank example with synchronized keyword
what is mean by hasing and maping in java platform and advantage?
can u draw class/object diagram for ATM
What is the use of the list interface in the java collection? : java collections
What are the different types of features of the java collections framework? : java collections
What is the difference between comparable and comparator in java.util pkg?
What are the different types of ways where you can iterate over a list? : java collections