更多"[单选题]C#语言中,字符串常量@'123\n456'的长度(有效字符"的相关试题:
[单选题]C#语言中,字符串常量@"123\n456"的长度(有效字符个数)是( )。
A.6
B.7
C.8
D.9
[单选题]下列选项中属于字符串常量的是:
A.'abc'
B."abc"
C.[abc]
D.(abc)
[单选题]下面不正确的字符串常量是( )。
A.'abc'
B."12'12"
C."0"
D." "
[单选题]在Word中进行替换时,替换字符串的长度( )被替换的字符串。
A.必须小于
B.必须大于
C.不必等于
D.必须等于
[单选题]判断字符串str1是否大于字符串str2,应当使用( )。
A.if(str1>str2)
B.if(strcmp(str1,str2)<0)
C.if(strcmp(str2,str1)>0)
D.if(strcmp(str1,str2)>0)
[判断题]根据国网公司标准要求,安全的口令,长度不得小于6 位字符串,要求是字母和数字或特殊字符的混合,用户名和口令可以相同。
A.正确
B.错误
[判断题]安全的口令,长度不得小于8位字符串,要求是大小写字母和数字或特殊字符的混合,用户名和口令禁止相同。
A.正确
B.错误
[单选题]字符串“IBM”中的字母B存放在计算机内占用的二进制位个数是( )。
A.8
B.4
C.2
D.1
[判断题]规范账号口令管理,口令必须具有一定强度、长度和复杂度,长度不得小于 8 位字符串,要求是字母和数字或特殊字符的混合,用户名和口令禁止相同
A.正确
B.错误
[单选题]下列程序的功能是统计字符串中"array"的个数,在程序的空白处应填入的正确选项是:
public class FindKeyWords{
public static void main(sring[] args){
String text=
" An array is a data structur that stores a collection of"
+ "values of the same type . You access each individual value"
+ "through an integer index . For example,if a is an array"
+ "of inergers, then a[i] is the ith integer in the array.";
int arrayCount =0;
int idex = -1;
String arrarStr ="array";
index = text.indexof(arrayStr);
while(index ______ 0) {
++arrayCount;
index += arrayStr.length();
index = text.indexof(arrayStr,index);
}
System.out.println("the text contains" + arrayCount + "arrays");
}
}
A.<
B.=
C.<=
D.>=
[单选题]C#中的字符型数据,均是Unicode字符,这样一个字符的标准长度为( )
A.4位
B.8位
C.16位
D.32位
[单选题]JS中使字符串中的字符变为小写的方法是
A.width
B.height
C.toLowerCase
D.Case
[单选题]下面哪个表达式可以获取字符串 s 的最后一个字符:
A.s.length()
B.s[s.length() - 1]
C.s.charAt(s.length() - 1)
D.charAt(s, length(s))
[单选题]若要求从键盘读入含有空格字符的字符串,应使用函数()。
A.getc()
B.gets()
C.getchar()
D.scanf()