丰富多彩、灿烂辉煌的中华文化由___________创造的 [ ]
A.汉族人民
B.少数民族人民
C.我国各族人民
D.世界各国人民
答案:C
下列给定程序中,函数fun()的功能是:在字符串str中找出ASCII码值最大的字符,将其放在第一个位置上,并将该字符前的原字符向后顺序移动。例如,调用fun()函数之前给字符串输入ABCDeFGH,调用后字符串中的内容为 eABCDFGH。 请改正程序中的错误,使它能得出正确的结果。 注意:不要改动main函数,不得增行或删行,也不得更改程序的结构。 试题程序: #include<stdio.h> /***************found************/ fun(char *p) char max, *q;int i=0; max=p[i]; while (p[i]!=0) if (max<p[i]) /***************found************/ p = q +i;max=p[i]; i++; /***************found************/ while (q<p)*q=*(q-1); q--; p[0]=max; main() char str[80]; printf("Enter a string: "); gets(str); printf("\nThe original string: "); puts(str); fun(str); printf("\nThe string after moving: "); puts(str); printf("\n\n");
以下程序的输出结果为______。 public class Course private String cNumber; private String cName; private int cUnit; public Course(String number, String name, int unit) cNumber = number;cName = name;cUnit = unit; public void printCourseInfo______ System.out.println("课程号:" + cNumber + " 课程名:" + cName + " 学分:" + cUnit); class CourseTest public static void main(String[] args) Course c;c = new Course("101", "ASP", 3);c.printCourseInfo______;