switch off light
来源:互联网 发布:电脑桌面软件太多 编辑:程序博客网 时间:2024/05/19 09:50
#include<stdio.h>
#include<string.h>
#define MAX 1010
int a[MAX];
int main()
{
int n,k,first=1;
memset(a,0,sizeof(a));
scanf("%d%d",&n,&k);
for(int i=1;i<=k;i++)
for(int j=1;j<=n;j++)
if(j%i==0) a[j]=!a[j];
for(int i=1;i<=n;i++)
if(a[i]) {
if(first)
first=0;
else
printf(" ");
printf("%d",i);
}
printf("\n");
return 0;
}
#include<string.h>
#define MAX 1010
int a[MAX];
int main()
{
int n,k,first=1;
memset(a,0,sizeof(a));
scanf("%d%d",&n,&k);
for(int i=1;i<=k;i++)
for(int j=1;j<=n;j++)
if(j%i==0) a[j]=!a[j];
for(int i=1;i<=n;i++)
if(a[i]) {
if(first)
first=0;
else
printf(" ");
printf("%d",i);
}
printf("\n");
return 0;
}
0 0
- switch off light
- Light on or off
- android disable the Auto light off
- FZU 1704 Turn off the light
- FZU 1704 Turn off the light
- switch off UDP checksum in kernel
- Switch Off the Touchpad(SONY VPCSD1S4C)
- mui-switch 修改 on off 文本
- FZUOJ 1704 Turn off the light (高斯消元+大数高精度)
- How to switch off the automatic assignment of employee relationship
- 学院OJ:1684:Light on or off __线段树 区间更新
- boss1接受light probe影响且能 cut off 且能 不透
- 【iOS遇到的问题】switch控件--在设置switch按钮状态为on或者off,运行app,模拟器黑屏
- Light
- 求助:Note: log switch off, only log_main and log_events will have logs!
- Note: log switch off, only log_main and log_events will have logs!
- 解决bootstrap switch 开关OFF被断开导致排版混乱的问题
- switch
- 用 ThreadLocal 管理用户session
- NKOI 3748 玩具取名
- 迷宫问题解法汇总
- C#入门10.5——抽象类与抽象方法声明
- python
- switch off light
- 演讲如何克服紧张情绪
- 模拟退火算法
- css布局之div + span 以及盒模型
- MySql按日/周/月分组统计数据
- leetcode-Reverse Bits-190
- 面向对象_main方法的格式详细解释
- 对Fragment的简单分析
- 关于权限模块的设计