suppose we have a string
String s = "hello how are you...";
char arr[] = s.toCharArray();
for(i = 0; i < arr.length; i++)
{
if(arr[i] 'u')
System.out.println(arr[i]);
}
that is it .I hope it works.If there is a better process let me know at :- "hello2.abhishek.pal@gmail.com"...
#!/usr/bin/perl print 'java program';
look at the print
For(int I = 0: I < 5; i++) { System.out.println(" print this " + I ); }
The Java console is a display of output sent by a Java program. This is similar to the MS DOS operating system.To print to the console, a programmer will type "println(text);" or "print(text);" depending is the programmer wants to make a new line after the text(println) or not(print).
You cannot do that. The main method of a java class is the point where the execution begins. You can print messages only after a main method is invoked.
In Java, you can print a birthday by using the System.out.println() method. For example, if you have a birthday stored in a variable, you can print it like this: String birthday = "January 1, 2000"; System.out.println("Birthday: " + birthday); This will display "Birthday: January 1, 2000" in the console. You can also format the date using the SimpleDateFormat class if you're working with Date objects.
In Java, the expression count-- is a post-decrement operator. It decreases the value of the variable count by 1, but it returns the original value of count before the decrement. This means that if you use count-- in an expression, you will get the value of count prior to it being decremented. For example, if count is 5, using count-- will yield 5 in the current expression, but afterwards, count will be 4.
Use text-editor notepad++
if x%5==0 { System.out.println("@"'); }
you press on the little square then click yes.. simple
public class welcome { public static void main (String args[]) { System.out.println("Welcome to Java programming"); } } There are also many "Hello World" tutorials you can find elsewhere on the internet
By using the static block