7701 |
3、使用字典统计字符串中每个字符出现的次数,横线上应该填写的代码是 dic = {} for c in 'an appl |
64 |
2024-04-21 |
7702 |
2、执行完下面代码后,输出的结果为( ) ls = [6, 1, 8, 6, 9, 6] n = len(ls) for i in range |
65 |
2024-04-21 |
7703 |
1、下面的程序,会无限循环下去的是( ) A:代码如下 for a in range(10000): time.sleep(10) B |
96 |
2024-04-21 |
7704 |
列表是包含0个或多个元素的无序类型 |
49 |
2024-04-21 |
7705 |
39 #include <iostream> using namespace std; int main() int n,m; cin >n >m; int x =1,y 1; |
0 |
2024-04-21 |
7706 |
40 #include <iostream> using namespace std; int main() { int n,m; cin >n>>m; int x 1, |
0 |
2024-04-21 |
7707 |
38 #include <iostream> using namespace std; int main( { int n,m; cin >n>>m; int x =1, |
0 |
2024-04-21 |
7708 |
37 #include <iostream> using namespace std; struct point { int x,y; : void add(point &a,point |
0 |
2024-04-21 |
7709 |
36 已知二叉树的前序遍历顺序为ABDCEGHF,中序遍历顺序为DBAGEHCF,该二叉树的后序遍历为___ |
0 |
2024-04-21 |
7710 |
35 int fun(int a,int b) if (b =0)return a; return fun(b,a b); 执行fun(84,119)函数返回值为___ |
0 |
2024-04-21 |
7711 |
34 假设字符串5="NOC23",则s的非空子串的个数为 |
0 |
2024-04-21 |
7712 |
33 假定一个二维数组的定义为char ch[8][8]:则该数组所占存储空间的字节总数为 |
0 |
2024-04-21 |
7713 |
C++语言中的每条基本语句以___作为结束符。(请填英文符号) |
0 |
2024-04-21 |
7714 |
31 对数组进行sort排序,reverse)反转,二分查找lower_.bound、upper_.bounds等操作需要包含头文件:<一>(本题横线 |
0 |
2024-04-21 |
7715 |
30 阅读以下程序 #include <iostream> using namespace std; int cnt[10]=() void split(int x) while (x 0 |
0 |
2024-04-21 |
7716 |
29对于长度为的数组,排序算法的最坏时间复杂度为0(n²)的是 A.选择排序 B.归并排序 C.插入排序 D.冒泡排序 |
0 |
2024-04-21 |
7717 |
28 阅读以下程序片段,下列选项中描述错误的是: int m; cin >m while (m%3==0) m/=3; while (m%5==0) { m/=5; |
0 |
2024-04-21 |
7718 |
27 现有两个已定义的int类型变量a,b,大小范围为(1<=a,b<=100),下列选项中, 能够实现交换a,b两 |
0 |
2024-04-21 |
7719 |
26 现有一字符串string s="Hello NOC!",下列关于该字符串的描述中,正确的是: A.s.substr(0,3)的结果是"Hell" |
0 |
2024-04-21 |
7720 |
25 对于一棵具有个结点,高度为h的任何二叉树,进行任一种次序遍历的时间复杂度均为 O(h)。 A.对 B.错 |
0 |
2024-04-21 |
7721 |
24二分搜索算法的基本思想是将n个升序排序的元素分成个数大致相同的两半,取a[/2] 与x进行比较:如果x<a[n/2], |
0 |
2024-04-21 |
7722 |
23广度优先搜索需要用到队列的数据结构,可以用来求最短路径。 A.对 B.错 |
0 |
2024-04-21 |
7723 |
22C++中的函数可以同时返回多个相同或者不同类型的返回值。 A.对 B.错 |
0 |
2024-04-21 |
7724 |
21 2_sum是一个合法的C++变量名。 A.对 B.错 |
0 |
2024-04-21 |
7725 |
20阅读以下程序片段,请问正确的输出结果是 intt=10001,X=0,y=0: while (t 0) { t--; X=t%8: if(X==1) y++; } |
0 |
2024-04-21 |