在C#中下列表达式不正确的是()。
第1题:
A.bool('')
B.bool(1)
C.bool(0)
D.bool([])
第2题:
自动类型转换是按优先关系从低级数据转换成高级数据,规定的优先次序是( )。
A.byte, short, char→int→long→float→double
B.float→int→long→byte, short, char→double
C.int→long→float→double→byte, short, char
D.double→int→float→long→byte, short, char
第3题:
自动类型转换规定的优先次序是( )。
A.short,byte,char→long→int→float→double
B.short,byte,char→int→long―float→double
C.byte,short,char→long→int→float→double
D.byte,short,char→int→long→float→double
第4题:
下面均为Java关键字的一组是()
A、boolean,byte,long,true
B、byte, long,true,goto
C、goto ,Boolean,byte,true
D、bool, long,true,auto
第5题:
有如下代码段 public class OperatorAndExceptions { public static void main(String args[]) { int i=10,j=15; System.out.println(i==j); String s1=new String("how are you!"); String s2=new String("how are you!"); System.out.println(s1==s2); } } 其输出为( )。
A.true false
B.true true
C.false true
D.false false
第6题:
下面程序的结果为______。
include<iostream.h>
void main()
{
int 3=1,b=2;
bool c=1;
if(a>b)||c)cout<<“true”<<endl;
else
cout<<“false”<<endl;
}
第7题:
D3DPRESENT_PARAMETERS参数很多,关于其中参数之一windowed的理解正确的是()
第8题:
如果已经定义了方法int f(bool b, int i),则以下方法中,哪一个不是合法的重载方法()。
第9题:
有如下程序段:int a = b = 5;String s1 = "祝你今天考出好成绩!";String s2 = s1; 则表达式a == b与s2 == s1的结果分别是()
第10题:
假设变量bool_x是一个布尔型(逻辑型)的变量,则下面正确的赋值语句是()
第11题:
您已创建一个名为 CalcSalary,将确定 Certkiller.com 员工的薪酬类的责任。CalcSalary 类包括员工的薪酬递增和递减的方法。下面的代码包含在 CalcSalary 类中:()public class CalcSalary {// for promotionspublic static bool IncrementSalary (Employee Emp, double Amount){if (Emp.Status == QuarterlyReview.AboveGoals)Emp.Salary += Amount;return true;
第12题:
double a,double b=2,int c=3,a=b+c
short a,byte b=2,byte c=3,a=b+c
string a,string b=”1” string c=”2” a=b+c
bool a,bool b=true,bool c=false a=b==c
第13题:
下面程序的结果为_____。
include<iostream.h>
void main( )
{
int a=1,b=2;
bool c=1;
if((a>b) | | c) cout < < "tree" < < endl;
else
cout < < "false" < < endl;
}
第14题:
下列代码的执行结果是( )。 public class Test{ public static void main String args[]){ String s1=new String("welcome"); String s2=new String("welcome"); System.out.println(s1==s2); System.out.println(s1.equals(s2)); } }
A.false,false
B.false,true
C.true,true
D.true,false
第15题:
若已经声明了函数原型“void fun(int a,double b=0.0);”,则下列重载函数声明中正确的是
A.void fun(int a=90,double b=0.0);
B.int fun(int a,double B) ;
C.void fun(double a,intB) ;
D.bool fun(int a,double b=0.0);
第16题:
基本数据类型精度从低到高排列正确的是()
A.byte short int float double
B.byte short int double float
C. short byte int float double
D. short byte int double float
第17题:
A.byte, short, int, long, float, double
B.boolean, byte, short, char, int, long, float, double
C.byte, short, char, int, long, float, double
D.byte, short, char
E.int, long, float, double
第18题:
第19题:
在C#中下列表达式不正确的是()。
第20题:
假设变量$x=5,则表达式“$x<>4”的返回值类型是()。
第21题:
bool类型只有2种值,为真(true)和假(false)。()
第22题:
You work as an application developer at Certkiller .com. You have been given the responsibility of creating a class named CalcSalary that will determine the salaries of Certkiller .com’s staff. The CalcSalary class includes methods to increment and decrement staff salaries. The following code is included in the CalcSalary class: public class CalcSalary { // for promotions public static bool IncrementSalary (Employee Emp, double Amount) { if (Emp.Status == QuarterlyReview.AboveGoals) Emp.Salary += Amount; return true; } else return false; } //for demotions public static bool DecrementSalary (Employee Emp, double Amount) { if (Emp.Status == QuarterlyReview.AboveGoals) Emp.Salary -= Amount; return true; } else return false; } } You would like to invoke the IncrementSalary and DecrementSalary methods dynamically at runtime from the sales manager application, and decide to create a delegate named SalaryDelegate to invoke them. You need to ensure that you use the appropriate code to declare the SalaryDelegate delegate.What is the correct line of code?()
第23题:
public delegate bool Salary (Employee Emp, double Amount);
public bool Salary (Employee Emp, double Amount);
public event bool Salary (Employee Emp, double Amount);
public delegate void Salary (Employee Emp, double Amount);
第24题:
double f(bool b, int i)
int f(double d, int i)
int f(bool b,int i, double d)
double f(bool d, int j)