Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Hay dem so luong chu le cua so nguyen duong n
- // Khai bao ham thu vien
- #include<stdio.h>
- #include<conio.h>
- void main()
- {
- int n;
- scanf("%d",&n);
- int dem =0;
- for(int i=1;i<=n;i++)
- {
- if(i%2!=0)
- {
- dem++;
- }
- }
- printf("%d",dem);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement