Content deleted Content added
LordDimwit (talk | contribs) |
No edit summary Tags: Reverted Mobile edit Mobile web edit |
||
Line 231:
The [[POSIX]] standard defines several extensions to {{mono|stdio}} in its Base Definitions, among which are a {{mono|readline}} function that allocates memory, the {{mono|fileno}} and {{mono|fdopen}} functions that establish the link between {{mono|FILE}} objects and [[file descriptor]]s, and a group of functions for creating {{mono|FILE}} objects that refer to in-memory buffers.<ref>{{man|bd|stdio.h|SUS}}</ref>
Write a c program to display the following 12 series by using for loops:
ii)10 11 12 13 ....20
iii)21 22 23 24 ...30
iv)31 32 33 34....50
v)1 2 3 4.....99 100
vi)2 4 6 8 10
vii)10 12 14 16.....60
viii)1 3 5 7....59
ix)51 53 55.....99
x)2 4 6 8.....96 98
xi) A B C D...Z
xii)a b c d....z
******************************************/
#include <stdio.h>
int main(
{ for(i=1;i<=5;i++){
}
printf("\n\nSeries 2:\n--------\n");
for
}
printf("\n\nSeries 3:\n--------\n");
for(i=21;i<=30;i++){
printf("%d\t",i);
▲ }
printf("\n\nSeries 4:\n--------\n");
for(i=31;i<=50;i++){
printf("%d\t",i);
}
printf("\n\nSeries 5:\n--------\n");
for(i=1;i<=100;i++){
printf("%d\t",i);
}
printf("\n\nSeries 6:\n--------\n");
for(i=2;i<=10;i=i+2){
printf("%d\t",i);
}
printf("\n\nSeries 7:\n--------\n");
for(i=10;i<=60;i=i+2){
printf("%d\t",i);
}
printf("\n\nSeries 8:\n--------\n");
for(i=1;i<=59;i=i+2){
printf("%d\t",i);
}
printf("\n\nSeries 9:\n--------\n");
for(i=51;i<=99;i=i+2){
printf("%d\t",i);
}
printf("\n\nSeries 10:\n--------\n");
for(i=2;i<=98;i=i+2){
printf("%d\t",i);
}
printf("\n\nSeries 11:\n--------\n");
char j;
for(j='A';j<='Z';j++){
printf("%c\t",j);
}
printf("\n\nSeries 12:\n--------\n");
char k;
for(k='a';k<='z';k++){
printf("%c\t",k);
}
}
==Alternatives to stdio{{anchor|Sfio}}==
|