在C程序中,设一表达式中包含有int,long,char和unsigned类型的变量和数据,这四种类型数据的转换规则是()。

A:int→unsigned→long→char B:char→int→long→unsigned C:char→int→unsigned→long D:int→char→unsigned→long

在表示C语言的整型变量时,表示”无符号短整型”的符号是( )。

A:unsigned int B:unsigned short C:long int D:unsigned long

类型修饰符unsigned修饰( )是错误的。

A:char B:int C:long int D:float

有如下程序:
#include <iostream.h>
using namespace std;
class Stack

public:
Stack(unsigned n=10):size(n)rep_=new int [size]; top=0;
Stack(Stack&s): size (s.size)

rep_=new int[size];
for(int i=0;i<size;i++)
rep_[i]=s.rep_[i];
top=s.top;

~Stack( )delete[]rep_;
void push(int

A:rep_[top]=a; top++;
int

在表示C语言的整型变量时,表示“无符号整型”的符号是 ( )

A:unsigned int B:unsigned short C:long int D:unsigned long

有以下定义和语句,则sizeof(a.share)的值是______。 struct date { unsigned int day; unsigned int mouth; unsigned int year; union{int share1; float share2; }share; }a;

类型修饰符unsigned修饰( )是错误的。

A:char B:int C:long int D:float

关键字unsigned不能修饰的类型是

A:char B:int C:float D:long int

微信扫码获取答案解析
下载APP查看答案解析