a_set=set(‘hello worldd!’)a_set.remove(‘a’)会报错
第1题:
下列程序的输出结果为( )。 #include (iostream) using namespace std; void main( ) char,a[ ] = { "hello" ," the" ," world" }; char * * pa = a: pa + +; cout << * pa << ENDL; }
A.hello
B.the
C.world
D.hellotheworld
第2题:
下列程序的输出结果为
#include<iostream.h>
void main( )
{
char * a[ ] ={"hello},"the"," world"};
char * * pa=a;
pa++;
cout < < * pa < < endl;
}
A.hello
B.the
C.world
D.hellotheworld
第3题:
下列程序的输出结果为 #include<iostream.h> void main() { char*a[]={"hello","the","world"}; char**pa=a; pa++; cout<<*pa<<end1; }
A.hello
B.the
C.world
D.hello the world
第4题:
A.1个Hello World
B.2个Hello World
C.3个Hello World
D.4个Hello World
第5题:
A. hello
B. hello2
C. 编译报错
D. 运行报错,不能将串与整数相加
第6题:
假设在UNIX操作系统环境下执行以下程序:
main()
{
printf("Hello World\n");
fork();
printf("Hello World\n");
}
若程序正常运行,子进程创建成功,那么,屏幕上得到输出的有
A.1个Hello World
B.2个Hello World
C.3个Hello World
D.4个Hello World
C
第7题:
第8题:
s=’hello world’,s[-4:]的值是()
第9题:
public class Foo { public void main( String[] args ) { System.out.println( “Hello” + args[0] ); } } What is the result if this code is executed with the command line?()
第10题:
’python’-"python"()的值是()
第11题:
对
错
第12题:
Hello
Hello Foo
Hello world
Compilation fails.
The code does not run.
第13题:
按照Java的标识符命名规则,下列表示常量的标识符规范的是
A.HelloWorld
B.HELLO_WORLD
C.hello_world
D.helloWorld
第14题:
下列程序的输出结果为 #include<iostream.h> void main( ) { char * a[ ]={"hello","the","world"}; char * * pa=a; pa++; cout <<*pa<<end1; }
A.hello
B.the
C.world
D.hellotheworld
第15题:
若定义cin>>str;当输入Hello World!,所得的结果是str= ______。
A.Hello World!
B.Hello
C.World
D.Hello World
第16题:
下列程序的输出结果是 #include <iostream> using namespace std; int main () { char a [] = "Hello,World": char*ptr = a; while (*ptr) { if(*ptr>= 'a' &&*ptr <='z' cout<<char{*ptr+'A'-'a'); else cout<<*ptr; ptr++; } return 0; }
A. HELLO. WORLD
B. Hello, World
C. hELLO, wORLD
D. hello, world
第17题:
下列程序的输出结果为
#include
void main()
{
char,a[]={”hello",”the",”world”};
char**pa=a:
pa++;
cout<<*pa<
}
A.hello
B.the
C.world
D.hellotheworld
第18题:
对于如下C语言程序 int main() { printf("Hello World\n"); fork(); printf("Hello World\n"); } 在UNIX操作系统中正确编译链接后,其正确的运行结果是
A.共打印出2行Hello World
B.共打印出3行Hello World
C.共打印出4行Hello World
D.共打印出5行Hello World
第19题:
执行以下代码会输出什么结果?() public class Test { StringgetStr(String s){ return s + “hello”; } public static void main(String arg[]) { Test t= new Test(); System.out.println(t.getStr(“LiLei/n”)); } }
第20题:
a_set=set(‘hello world!’)a_set.discard(‘a’)会报错。
第21题:
下列标识符中,合法的是()。
第22题:
语句PrintFormat(“Hello World”,“>”)的输出结果是()。
第23题:
对
错