问题标题: 酷町堂:小李工作室:0001 可怕的随机数

0
0
已解决
李熙尧
李熙尧
中级守护
中级守护

0001    可怕的随机数                                                                                                                    经验值:20

题目描述 Description

上课时,李奕歌的老师抽签回答问题,(他们班一共有10人),老师想让这次抽到的人以后都让他回答

请你设计一个程序帮帮老师吧!

输入描述 Input Description

                无

 

输出描述 Output Description

           1~10(两次)

样例输入 Sample Input

 

样例输出 Sample Output

 


1
已采纳
郑泓毅
郑泓毅
资深守护
资深守护

#include<iostream>

using namespace std;

int main(){

    while(true){

        cout<<"李奕歌"<<endl;

    }
}

0
戈思越
戈思越
新手光能
新手光能

??????

戈思越在2021-03-30 20:34:17追加了内容

是让写题吗?

0
0
王子逸
王子逸
新手天翼
新手天翼

#include<iostream>

#include<ctime>

#include<cstdlib>

using namwespace std;

int main()

{

int a;

srand(timt(NULL));

a=rand()%10+1;

cout<<a<<endl;

a=rand()%10+1;

cout<<a;

}

0
王子逸
王子逸
新手天翼
新手天翼

#include<iostream>

#include<ctime>

#include<cstdlib>

using namespace std;

int main()

{

int a;

srand(timt(NULL));

a=rand()%10+1;

cout<<a<<endl;

a=rand()%10+1;

cout<<a;

}

0
0
朱小川
朱小川
缔造者
缔造者

??

朱小川在2021-03-28 15:35:42追加了内容

你是对那人有仇吗

0
王子桐
王子桐
高级光能
高级光能

#include<iostream>

#include<ctime>

#include<cstdlib>

using namwespace std;

int main()

{

int a;

srand(timt(NULL));

a=rand()%10+1;

cout<<a<<endl;

a=rand()%10+1;

cout<<a;

}

0
0
我要回答