なんとな~くしあわせ?の日記

「そしてそれゆえ、知識そのものが力である」 (Nam et ipsa scientia potestas est.) 〜 フランシス・ベーコン

2011-11-08から1日間の記事一覧

C言語でchar文字判定

1 #include <iostream> 2 #include <stdio.h> 3 #include <string.h> 4 5 using namespace std; 6 7 int main(){ 8 9 string sjis = "\x88\xa2\x82\x70\x90\xb3\x93\x60"; 10 cout << sjis << endl; 11 12 for ( int i = 0;i < sjis.length(); i++){ 13 char hex[3]; 14 char testHex[8]; </string.h></stdio.h></iostream>…