in C#
int number1,number2;
Console.WriteLine("The numbers entered are {0} and {1}", number1, number2 );
in C
int i;
printf("%d", i);
Loop迴圈
for loop:
int n=10;
for(int i=0;i<n;i++){
System.out.println(i);
}
while loop:
int n=10;
int i=0;
while(i<n){
System.out.println(i);
i++;
}
do while loop:
int n=10;
int i=0;
do{
System.out.println(i);
i++;
}while(i<n);
指定Java字元值
沒有留言:
張貼留言