本文共 450 字,大约阅读时间需要 1 分钟。
嘿嘿,太水了,代码上
#include#include #include #include using namespace std;void color(unsigned int ForeColor=7,unsigned int BackGroundColor=0) { HANDLE handle=GetStdHandle(STD_OUTPUT_HANDLE); SetConsoleTextAttribute(handle,ForeColor+BackGroundColor*0x10);}int main(){ srand(time(NULL)); while(1){ int t=rand()%8,k=rand()%8; color(t,k); cout<<" "; } return 0;}
哈哈
转载地址:http://muggf.baihongyu.com/