String s = \abcdedcba
![](/upload/20220827/c85071da6ff0aadc10ebce6c25bb4f0d.png)
相似题目
-
public class X { public static void main (String[]args) { string s = new string (“Hello”); modify(s); System.out.printIn(s); } public static void modify (String s) { s += “world!”; } } What is the result?()
-
现有代码片段: String s="123"; String sl=S+456; 请问sl的结果是哪项?()
-
下面程序的输出结果是() public class Test{ public static void main(String[] args){ String s = “abc dsf ghi”; String[] arr = s.split(“\s”); System.out.println(arr.length); } }
-
11. String test= “a1b2c3”; 12. String[] tokens = test.split(”\\d”); 13. for(String s: tokens) System.out.print(s +“ “); What is the result?()
-
public String makinStrings() { String s = “Fred”; s = s + “47”; s = s.substring(2, 5); s = s.toUpperCase(); return s.toString(); } How many String objects will be created when this method is invoked?()
-
Given: 11.String test = "a1b2c3"; 12.String[] tokens = test.split("\\d"); 13.for(String s: tokens) System.out.print(s + " "); What is the result?()
-
public class X { public static void main (Stringargs) { string s = new string (“Hello”); modify(s); System.out.printIn(s); } public static void modify (String s) { s += “world!”; } } What is the result?()
-
请问如下哪些语句正确?(多选)A: String s1=”abc”; String s2=”abc”;则s1= =s2B: String[] s=”abc”;C: new String s=”abc”;D: String s=new String(“abc”);
-
下面代码的运行结果为:( )import java.io.*;import java.util.*;public class foo{public static void main (String[] args){String s;System.out.println(s= + s);}}
-
已知代码: String s = story
-
读代码:public class foo {static String s;public static void main (String[]args) {System.out.println (“s=” + s);}}结果是:
-
有如下程序段:public class ish{public static void main(String[] args) {String s='call me ishmae';System.out.println(s.charAt(s.length()-1));}}则输出结果为?
-
已知 String 对象 s='abcdefg',则 s.substring(2, 5)的返回值为?( )
-
public static void main(String[] args) {LinkedList list=new LinkedList();list.add(\A\);list.add(\B\);String s=(String)list.get(2);System.out.println(s);}编译运行的结果是
-
执行下列代码后,哪个结论是正确的 String[] s=new String[10];
-
现有代码片段:String s=\123
-
执行下面代码后,( )结论是正确的. String[] s=new String[10];
-
String s = new String("xyz"),以下( )语句将改变s的值。
-
下列的哪个程序段可能导致错误?()A.String s="hello"; String t="good"; String k=s+t;B.String
-
String s = new String();创建了几个String Object()
-
执行”String[] s = new String[10];”语句后,结论正确的是()
-
下列程序运行后的输出结果是_public class Foo{ public static void main(String[] args){ String s; System.out.println(“s=” + s); }}()
-
执行下列代码后,哪个结论是正确的 String()s=new String
-
下面的代码输出结果是什么?string s{“”};s.append(“ABCDEFG”, 3, 2);cout << s;()