C言語検定(2級)

Contents

C言語検定試験について

試験名

C言語プログラミング能力認定試験
(C-Language Programming Skills Qualification Test)

試験目的

C言語を駆使して応用プログラム(言語処理系、ユーティリティなど)を作成する能力を認定します。

認定基準

一級 C言語を駆使し、応用プログラム(言語処理系、ユーティリティなど)が作成できる能力を有する。また使用しているOSについて理解をしている。
二級 小規模のプログラム(500行程度)が適切に(理路整然、簡潔、正しく、速く)書ける。また各種基本アルゴリズムを理解している。
三級 C言語の概念を理解し、簡単なプログラムが書ける。

 

参考(2級出題範囲)

出題内容
定数 浮動小数点定数 指数形式を許す
浮動小数点接尾語はf、l、F、Lのいずれか
整数定数 整数接尾語として長語接尾語(l、L)を含む
文字定数 拡張表記は8進拡張表記、16進拡張表記を含む
文字列リテラル 拡張表記は8進拡張表記、16進拡張表記を含む
列挙定数
演算子 ビット演算子、条件演算子、代入演算子、キャスト演算子、ポインタ/アドレス演算子、構造体演算子、sizeof演算子
宣言指定子 void、short、long、float、double、構造体共用体指定子(struct、union)、列挙型指定子(enum)、型修飾子(const)、typedef
変数 上記型指定子の単純変数、配列
外部定義
プリプロセッサ機能 ファイルの包含
ライブラリ関数
数学関数<math.h>
double cos(double x); double sin(double x);
double tan(double x); double exp(double x);
double log(double x); double log10(double x);
double pow(double x, double y);
double sqrt(double x); double ceil(double x);
double fabs(double x); double floor(double x);
入出力関数<stdio.h>
NULL、EOF、FILE、stderr、stdin、stdout、
FILE *fopen(const char *filename, const char *mode);
int fclose(FILE *stream);
int fscanf(FILE *stream, const char *format, …);
int fprintf(FILE *stream, const char *format, …);
int sscanf(const char *s, const char *stream, …);
int sprintf(char *s, const char *stream, …);
int fgetc(FILE *stream, …); int fputc(int c, FILE *stream);
char *fgets(char *s,int c, FILE *stream);
int fputs(const char *s, FILE *stream);
int getc(FILE *stream, …); int putc(int c, FILE *stream);
char *gets(char *s);int puts(const char *s);
int ungetc(int c, FILE *stream);
一般ユーティリティ関数<stdlib.h>
NULL  double atof(const char *nptr);
int atoi(const char *nptr);
long int atol(const char *nptr);
int rand(void);  void srand(unsigned int seed);
int abs(int i);  long int labs(long int j);
文字列操作関数<string.h>
NULL  size_t
char *strcpy(char *sl,const char *s2);
char *strncpy(char *sl,const char *s2, size_t n);
char *strcat(char *sl,const char *s2);
char *strncat(char *sl,const char *s2, size_t n);
int strcmp(const char *sl,const char *s2);
int strncmp(const char *sl,const char *s2, size_t n);
char *strchr(const char *s, int c);
char *strrchr(const char *s, int c);
char *strstr(const char *sl, const char *s2);
size_t strlen(const char *s);
その他
  • main関数の引数、整数型以外の関数
  • 自己参照構造体
  • 変数の記憶クラスと通用範囲(auto、static、register、extern)

※3級出題範囲含む

注)各級とも日本工業規格 (JIS) X3010 で出題・解答する。