以下程序段的输出结果是 。Char s[ ]=”Hello World!”;Strlwr(s);Printf(“%s”,s);
A: hello world!
B: HELLO world!
C: hello WORLD!
D: HELLO WORLD!
A: hello world!
B: HELLO world!
C: hello WORLD!
D: HELLO WORLD!
A
举一反三
- 下面程序段的输出结果是_______。for s in "Hello, World!": if s==",": break print(s,end="") A: Hello, B: Hello,World! C: , D: Hello
- 若字符串 s = 'hello world',则语句 s.ljust(15, '.') 和 s.rjust(15) 的输出结果为? A: '....hello world'' hello world' B: 'hello world....'' hello world' C: 'hello world....''hello world ' D: 'hello world....''hello world'
- for s in "hello world": A: hello world B: world C: hello D: helloworld
- 以下要输出“hello,world!”正确的是? A: String s=String.format("%1s%2s","hello","world");System.out.println(s); B: String s=String.format("%1$s,%2$s","hello","world");System.out.println(s); C: String s=String.format("%s,%s","hello","world");System.out.println(s); D: String s=String.format("%1s,%2s","hello","world");System.out.println(s);
- 下面代码的输出结果是()for s in “Hello World”:if s==”W”:contineprint(s,end=” “) A: Hello orld B: Hello C: World D: HelloWorld
内容
- 0
给定一个java程序的代码片断如下,运行后正确的输出结果是( )。String s=”hello, world”;String str = s.replace(“,” , ” ”);System.out.println(str); A: hello world; B: hello, world C: HELLO WORLD D: HELLO ,WORLD;
- 1
s="Hello World",s[::-1]输出什么内容? A: “Hello Worl” B: “Hello World” C: 'lroW olle' D: 'dlroW olleH'
- 2
下列选项中,()是正确的JSP表达式。 A: <;% String s="hello world";%>; B: <;%=hello world";>; C: <;%="hello world"%>; D: <;%!"hello world"%>;
- 3
8、下列选项中,()是正确的表达式。 A: <;% String s="hello world"; %>; B: <;%="hello world"; %>; C: <;% ="hello world" %>; D: <;%! "hello world" %>;
- 4
print("hello"+"world")的输出结果是。 A: “hello”world B: hello world C: "hello"+world D: helloworld