KS X 2012-2007 Information technology-C language in unix environment《UNIX环境下的C语言》.pdf

上传人:progressking105 文档编号:821528 上传时间:2019-02-12 格式:PDF 页数:124 大小:786.46KB
下载 相关 举报
KS X 2012-2007 Information technology-C language in unix environment《UNIX环境下的C语言》.pdf_第1页
第1页 / 共124页
KS X 2012-2007 Information technology-C language in unix environment《UNIX环境下的C语言》.pdf_第2页
第2页 / 共124页
KS X 2012-2007 Information technology-C language in unix environment《UNIX环境下的C语言》.pdf_第3页
第3页 / 共124页
KS X 2012-2007 Information technology-C language in unix environment《UNIX环境下的C语言》.pdf_第4页
第4页 / 共124页
KS X 2012-2007 Information technology-C language in unix environment《UNIX环境下的C语言》.pdf_第5页
第5页 / 共124页
点击查看更多>>
资源描述

1、 KS X 2012 KSKSKSKS SKSKSKS KSKSKS SKSKS KSKS SKS KS C KS X 2012 : 2007 (2012 ) 2007 10 30 http:/www.kats.go.krKS X 2012:2007 : ( ) ( ) SJ ( ) : () ( ) Microsoft IBM KS X 2012:2007 : (http:/www.standard.go.kr) : :1992 12 17 :2007 10 30 :2012 12 28 : 2012-0797 : (JTC1/SC22) ( 02-509-7262) (http:/www.

2、kats.go.kr). 10 5 , . KS X 2012:2007 i 1 1 2 .1 3 .2 3.1 2 3.2 4 4 .9 4.1 9 4.2 .18 4.3 .19 4.4 27 4.5 .28 4.6 .34 4.7 36 4.8 (preprocessing directives) .38 5 (Library).43 5.1 .43 5.2 45 5.3 45 5.4 .51 5.5 54 5.6 59 5.7 .60 5.8 61 5.9 /62 5.10 80 5.11 88 5.12 96 A() C 100 A.1 .100 A.2 .108 A.3 .114

3、KS X 2012 : 2007 (2012 ) C Information technology C language in unix environment 1 C , C . a) C b) C c) C d) C e) C f) C g) 2 . a) LANG , , . LANG locale . b) LC-COLLATE c) LC-CTYPE d) LC-MONETARY e) LC-NUMERlC f) LC-TIME g) Locale . 1 . h) NLSPATH i) (empty string) j) , . , , , . . k) , l) m) n) ,

4、 o) KS X 2012:2007 2 . “ ” “ ” . p) . q) . . , . , . r) 2 s) . . t) (decimal-point character) . , setlocale . u) (string) . . v) w) x) . “” “ ” . y) (alignment) z) , , . . aa) ab) (local custom) , , ac) (localization) , , ad) ae) KS X 1001, ( ) af) . , “W” . 3 3.1 3.1.1 C . . #include . . , , . , .

5、 . a) ( ) KS X 2012:2007 3 . b) . , . c) ( ) . . , . . d) , . #include 1 4 . e) (escape sequence) . f) , . g) . . . h) . . . ( ) . . 3.1.2 2 . C . ( ) . . . a) (C ) . . . . b) , . main. . . int main (void)/*/ 2 ( , argc argv ) . int main (int argc, char *argv) /*/ main , . 1) argc . 2) argvargc . 3)

6、 argc 0 , argv0 argvargc-1 . . KS X 2012:2007 4 . , . 4) argc 0 , argv0 . argv00 . argc 1 argv1 argvargc-1 . 5) argc argv argv , . , , , . main main exit . main . c) , , . . (sequential point) , . . ( ). , . . , . . 1) , . 2) . 3) 5.9 . . 3.2 3.2.1 2 . . . 0 (null character) , . . KS X 2012:2007 5 2

7、6 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z 26 a b c d e f g h i j k l m n o p q r s t u v w x y z 10 10 0 1 2 3 4 5 6 7 8 9 29 ! # % ? - 1 , , (form feed) . , . , , (carrige return), . ( , , , , ) . a) . , . . 1) 3.2 . 2) , (locale-specific). 3) (state-dependent) . 4) 0 . 5) 0 2 . . 1) ,

8、 . 2) , , . 3.2.2 fputc . (isprint ) , . . . . a() . . b() . KS X 2012:2007 6 . f( ) n() r() t( ) . . v( ) . . 3.2.3 ( , , ) , . ( ) . , . 3.2.4 a) 1 . 1) , , 15 2) 8 3) , , , 12 , , 4) 31 5) 32 6) 31 7) 6 8) 511 9) 127 10) 1024 11) 31 12) 31 13) 31 14) 509 15) 509 ( ) 16) 32767( ) 17) #include 8 1

9、8) switch 257 case ( switch ) 19) 127 20) 127 21) 15 b) (limits. h (float. h . 1) (limits.h CHAR-BIT MB-LEN-MAX . KS X 2012:2007 7 , () . 1.1) () CHAR_BIT 8 1.2) signed char SCHAR_MIN 127 1.3) signed char SCHAR_MAX 127 1.4) unsigned shar UCHAR_MAX 255 1.5) char CHAR_MIN 127, 0 1.6) char CHAR_MAX 127

10、 255 1.7) MB_LEN_MAX 2 1.8) short int SHRT_MIN 32764 1.9) short int SHRT_MAX 32767 1.10) unsigned short int USHRT_MAX 65535 1.11) int INT_MIN 32767 1.12) int INT_MAX +32767 1.13) unsigned int UINIT_MAX 65535 1.14) long int LONG_MIN 2147483647 1.15) long int LONG_MAX 2147483647 1.16) unsigned long i

11、nt ULONG_MAX 4294967295 2) . KS X 2012:2007 8 s (1) b , ( 1) e (e min e max ) p ( b ) f kb x(f 1 0, x0) . xsb e p 1 k k f b K , e min e e max FLT-RADIX #if . . FLT-RADIX FLT-ROUNDS 3 . FLT-ROUNDS . FLT-ROUNDS . 1 0 0 1 2 3 FLT-RADIX . , () . 2.1) FLT_RADIX 2 2.2) FLT-RADIX FLT_MANT_DIG DBL_MANT_DIG

12、LDBL_MANT_DIG 2.3) q q b p , q . (p1)*log 10 b FLT_DIG 6 DBL_DIG 10 LDBL_DIG 10 2.4) FLT-RADIX 1 (e min ). FLT_MIN_EXP DBL_MIN_EXP LDBL_MIN_EXP 2.5) 10 . 1og 10 b e (e e min 1) FL T_MIN_10_EXP 37 DBL_MIN_10_EXP 37 LDBL_MIN_10_EXP 37 2.6) FLT-RADIX 1 (e max ). FLT_MAX_EXP 1, b 10 0, KS X 2012:2007 9

13、DBL_MAX_EXP LDBL_MAX_EXP 2.7) 10 . log 10 (1b p )b e (e e max ) FLT_MAX_10_EXP 37 DBT_MAX_10_EXP 37 LDBL_MAX_10_EXP 37 () . 2.8) (1b -p )b e (e e max ) FL T_MAX 1E 37 DBL_MAX 1E 37 LDBL_MAX 1E 37 () . 2.9) 1 1 (b 1P ) FLT_EPSILON 1E5 DBL_EPSILON 1E9 LDBL_EPSILON 1E 9 2.10) (:b :e min 1) FL T_MIN 1E

14、37 DBL_MIN 1E 37 LDBL_MIN 1E 37 4 4.1 a) token: keyword identifier constant string-literal operator punctuator preprocessing-token: header-name identifier pp-number character-constant string-literal operator punctuator KS X 2012:2007 10 b) , . (keyword), (identifier), (constant), (string literal), (

15、operator), (punctuator) . (preprocessing token) . (header name), , (preprocessing number), (character constant), , , (non-white-space) . “ ” . (white-space) , (space), / , , . . , . 4.1.1 a) keyword: auto double int struct break else long switch case enum register typedef char extern return union const float short unsigned continue for signed void default goto sizeof volatile do if static while b) ( ). 4.1.2 a) identifier: nondigit identifier nondigit identifier digit nondigit: - a b c d e f g h i j k l m n o p q r s t u v w x y z A B C D E F G H I J K L M N O P

展开阅读全文
相关资源
猜你喜欢
  • BS ISO 10896-4-2015 Rough-terrain trucks Safety requirements and verification Additional requirements for variable-reach trucks handling freely suspended loads《崎岖地形卡车 安全要求和验证 伸缩臂式卡.pdf BS ISO 10896-4-2015 Rough-terrain trucks Safety requirements and verification Additional requirements for variable-reach trucks handling freely suspended loads《崎岖地形卡车 安全要求和验证 伸缩臂式卡.pdf
  • BS ISO 10896-5-2015 Rough-terrain trucks Safety requirements and verification Interface between rough-terrain truck and integrated personnel work platform《崎岖地形卡车 安全要求和验证 崎岖地形卡车和集成人.pdf BS ISO 10896-5-2015 Rough-terrain trucks Safety requirements and verification Interface between rough-terrain truck and integrated personnel work platform《崎岖地形卡车 安全要求和验证 崎岖地形卡车和集成人.pdf
  • BS ISO 10896-6-2015 Rough-terrain trucks Safety requirements and verification Tilting operator-s cabs《崎岖地形卡车 安全要求和验证 可倾驾驶室》.pdf BS ISO 10896-6-2015 Rough-terrain trucks Safety requirements and verification Tilting operator-s cabs《崎岖地形卡车 安全要求和验证 可倾驾驶室》.pdf
  • BS ISO 10896-7-2016 Rough-terrain trucks Safety requirements and verification Longitudinal load moment systems《崎岖地形卡车 安全要求和验证 纵向载荷力矩系统》.pdf BS ISO 10896-7-2016 Rough-terrain trucks Safety requirements and verification Longitudinal load moment systems《崎岖地形卡车 安全要求和验证 纵向载荷力矩系统》.pdf
  • BS ISO 10897-2016 Collets for tool holders with taper ratio 1 10 Collets holders nuts《锥度比为1 10的刀架夹头 夹头、刀架和螺母》.pdf BS ISO 10897-2016 Collets for tool holders with taper ratio 1 10 Collets holders nuts《锥度比为1 10的刀架夹头 夹头、刀架和螺母》.pdf
  • BS ISO 10898-2016 Spot drills《定心钻》.pdf BS ISO 10898-2016 Spot drills《定心钻》.pdf
  • BS ISO 10904-2011 Fibre-cement corrugated sheets and fittings for roofing and cladding《屋顶和覆盖层纤维水泥波纹板及其配件》.pdf BS ISO 10904-2011 Fibre-cement corrugated sheets and fittings for roofing and cladding《屋顶和覆盖层纤维水泥波纹板及其配件》.pdf
  • BS ISO 10907-1-2008 Tools for moulding - Locating rings - Locating rings for mounting without thermal insulating sheets in small or medium moulds (types A and B)《模具 定位环 小型或中型模具内无绝热.pdf BS ISO 10907-1-2008 Tools for moulding - Locating rings - Locating rings for mounting without thermal insulating sheets in small or medium moulds (types A and B)《模具 定位环 小型或中型模具内无绝热.pdf
  • BS ISO 10907-2-2007 Tools for moulding Locating rings Locating rings for mounting with thermal insulating sheets in small or medium moulds (types C and D)《铸模工具 定位环状物 小型或中型模具中安装有隔热板.pdf BS ISO 10907-2-2007 Tools for moulding Locating rings Locating rings for mounting with thermal insulating sheets in small or medium moulds (types C and D)《铸模工具 定位环状物 小型或中型模具中安装有隔热板.pdf
  • 相关搜索

    当前位置:首页 > 标准规范 > 国际标准 > 其他

    copyright@ 2008-2019 麦多课文库(www.mydoc123.com)网站版权所有
    备案/许可证编号:苏ICP备17064731号-1