int main(){ int a[10]; hoge(a); int *b; hoge(b); int c[5]; hoge(c); hoge(0); return 0; }
int main(){ const long long p = 2; MOD hoge(1,p); MOD a = hoge + 1; std::cout << a << std::endl; return 0; }
int main() { hoge(); printf("hello world"); return 0; }
int main() { clx::json hoge( "ringo : [1,2,3, { \"age\" : 100, \"boo\": \"poo\" } ] " ); int aa[10] = {1,2,3,4,5,5,5,5,5,5}; hoge["aho"] = 100; hoge["aho"] = "asdfasdf"; std::cerr << "x:" << hoge.string().size() << std::endl; }
int main(){ for(int i=0;i<10;i++) a[i] = 0; xmp_sync_all(NULL); if(xmp_node_num() == 1) hoge(3, 2, -9); xmp_sync_all(NULL); if(xmp_node_num() == 2){ if(a[3] == -9){ printf("PASS\n"); } else{ fprintf(stderr, "ERROR\n"); exit(1); } } return 0; }
void Mamusu::Initialize(){ field1 = LoadGraph("umi.png"); field2 = LoadGraph("ki1.png"); field3 = LoadGraph("sougenn1.png"); field4 = LoadGraph("miti.png"); field5 = LoadGraph("tairu.png"); field6 = LoadGraph("yougann.png"); field7 = LoadGraph("hatti.png"); field8 = LoadGraph("hatti1.png"); field9 = LoadGraph("burokku.png"); field10 = LoadGraph("burokku1.png"); field11 = LoadGraph("burokku2.png"); Field hoge("mamusu.csv",field1,field2,field3,field4,field5,field6,field7,field8,field9,field10,field11,50,51);//最初のステージ field = hoge; int src[16]; LoadDivGraph("mobu1.png",16,4,4,32,32,src);//主人公の素材 mobus = 10; mobu = new Mobu[mobus]; Mobu hige("まむすのむらへ、ようこそ。Bここに いれば、あんぜんです。",src,23,12,true); Mobu hige1("もうひとつのむら でうす の みんなは、Bなぞの びょうきで、 たおれている",src,24,11,true); Mobu hige2("むらの すがたが みえないのは、みんなのBちからを あわせて すがたを、Bけしているからです",src,27,38,true); Mobu hige3("りばいるの くすりは、Bやむのみ あえのみ るくのみの じゅんばんでBちょうごうすると できる。",src,16,26,true); Mobu hige4("このさきは、4にん そろって いかないと、Bきけんだ。Bだれも もどってきたものが、いない。",src,39,37,true); Mobu hogehoge("nurse",src,20,38,true); Mobu rebirth("rebirth",src,13,34,true); Mobu higehige("buyer_arms",src,12,12,false); Mobu buyer_guard("buyer_guard",src,12,17,false); Mobu chemist("chemist",src,22,20,false); mobu[0] = hige; mobu[1] = hogehoge; mobu[2] = higehige; mobu[3] = buyer_guard; mobu[4] = chemist; mobu[5] = rebirth; mobu[6] = hige1; mobu[7] = hige2; mobu[8] = hige3; mobu[9] = hige4; }
extern "C" int main() { std::string hoge("Hello World!"); std::cout << hoge << std::endl; Roulette::Delay(100); Timer timer; boost::array<char, 256> buf; while (true) { size_t n = read(STDIN_FILENO, buf.data(), buf.size() - 1); if (n > 0) { buf[n] = '\0'; write(STDOUT_FILENO, buf.data(), n); } Roulette::Update(); timer.WaitMs(1000); } return 0; }
int main (int argc, char * * argv) { printf("Hello World!\n"); hoge(); return (0); }
int main() { char *p; p = hoge(); printf( "%s\n",p ); }
int main() { int aho[5]; hoge(aho); }
void main() { #ifdef process1 // vector 2.741 2.597 2.605 (s) // list 2.42 2.464 2.43 (s) for (int i = 0; i < 1000000; i++) { Hoge hoge(i % 5); g_hoge.push_back(hoge); } #endif #ifdef process2 // vector 1.482 1.568 1.501 (s) // list 2.646 2.687 2.67 (s) for (int i = 0; i < 1000000; i++) { g_pHoge.push_back(new Hoge(i % 5)); } #endif long start = clock(); { #ifdef process1 // vector(配列アクセス) 0.373 0.379 0.38 // vector(イテレータ) 1.789 1.793 1.792 // list 2.001 1.999 1.992 // ↓ erase付き // vector 計測不可能 // list 2.773 2.785 2.783 //for (int i = 0; i < 1000000; i++) //{ // g_hoge[i].a++; //} auto it = g_hoge.begin(); while (it != g_hoge.end()) { if ((*it).a == 1) { it = g_hoge.erase(it); continue; } (*it).a++; it++; } #endif #ifdef process2 // vector(配列アクセス) 0.445 0.366 0.369 // vector(イテレータ) 1.81 1.825 1.808 // list 2.112 2.013 2.001 // ↓ erase付き // vector 22.782 22.132 22.923 // list 2.898 2.890 2.885 //for (int i = 0; i < 1000000; i++) //{ // g_pHoge[i]->a++; //} auto it = g_pHoge.begin(); while (it != g_pHoge.end()) { if ((*it)->a == 1) { delete (*it); it = g_pHoge.erase(it); continue; } (*it)->a++; it++; } #endif } long goal = clock(); printf("sec : %f", (float)(goal - start) / CLOCKS_PER_SEC); getchar(); }
int main() { std::cout << VALUE << std::endl; hoge(); return 0; }