if (i % 2 != 0) {continue;
}
sum = sum + i;
}
System.out.print("1到10之间的所有偶数的和为:" + sum);
}
}
System.out.print("1到10之间的所有偶数的和为:" + sum);
}
}
}
sum = sum + i;
}
System.out.print("1到10之间的所有偶数的和为:" + sum);
}
}
System.out.print("1到10之间的所有偶数的和为:" + sum);
}
}
2015-07-01
public class HelloWorld
{
public static void main(String[] args)
{
String love="我爱慕课网";
String you="www.baidu.com";
System.out.println(love);
System.out.println(you);
}
}
{
public static void main(String[] args)
{
String love="我爱慕课网";
String you="www.baidu.com";
System.out.println(love);
System.out.println(you);
}
}
2015-07-01
public class HelloWorld{
public static void main(String[] args) {
final char male='男';
final char female='女';
char k='\n';
System.out.println("male表示:"+male+k+"female表示:"+female);
}
}
public static void main(String[] args) {
final char male='男';
final char female='女';
char k='\n';
System.out.println("male表示:"+male+k+"female表示:"+female);
}
}
2015-07-01
public class HelloWorld{
public static void main(String[] args) {
String a_ ="我爱慕课网";
char a_1 ='\n';
String b_ ="www.imooc.com";
System.out.println(a_ + a_1 + b_);
}
}
public static void main(String[] args) {
String a_ ="我爱慕课网";
char a_1 ='\n';
String b_ ="www.imooc.com";
System.out.println(a_ + a_1 + b_);
}
}
2015-07-01
public class HelloWorld{
public static void main(String[] args) {
String a_ ="我爱慕课网";
System.out.println(a_);
a_ ="www.imook.com";
System.out.println(a_);
}
}
WRONG
public static void main(String[] args) {
String a_ ="我爱慕课网";
System.out.println(a_);
a_ ="www.imook.com";
System.out.println(a_);
}
}
WRONG
2015-07-01
if(score>80){
if(sex=="男"){System.out.println("进入男子组决赛");
}
else{
System.out.println("进入女子组决赛");
}
}else{
System.out.println("不能进入决赛");
}
if(sex=="男"){System.out.println("进入男子组决赛");
}
else{
System.out.println("进入女子组决赛");
}
}else{
System.out.println("不能进入决赛");
}
2015-06-30
public class HelloWorld{
public static void main(String[] args) {
String city = "成都";
System.out.println("我的家乡在:"+city);
}
}
public static void main(String[] args) {
String city = "成都";
System.out.println("我的家乡在:"+city);
}
}
2015-06-30
public class HelloWorld{
public static void main(String[] args) {
String s1 = "我爱慕课网";
String s2 = "www.imooc.com";
System.out.println(s1);
System.out.println(s2);
}
}
public static void main(String[] args) {
String s1 = "我爱慕课网";
String s2 = "www.imooc.com";
System.out.println(s1);
System.out.println(s2);
}
}
2015-06-30
public class HelloWorld{
public static void main(String[] args) {
String hobby="我爱慕课网";
String tony="www.imooc.com";
System.out.println(hobby);
System.out.println(tony);
}
}
public static void main(String[] args) {
String hobby="我爱慕课网";
String tony="www.imooc.com";
System.out.println(hobby);
System.out.println(tony);
}
}
2015-06-30