Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
arrays vowles printing
//gcc 4.9.3 #include <stdio.h> #include <stdlib.h> void input(int *p,int n) { int i; srand(getpid()); for(i=0;i<n;i++) { p[i]=rand()%26+65; printf("a[%d]=%c\n",i,p[i]); } } void vowles(int *p,int n) { int i,ch; printf("***VOWLES***\n"); for(i=0;i<n;i++) { switch(p[i]) { case 'A':printf("p[%d]=%c\n",i,p[i]); break; case 'E':printf("p[%d]=%c\n",i,p[i]); break; case 'I':printf("p[%d]=%c\n",i,p[i]); break; case 'O':printf("p[%d]=%c\n",i,p[i]); break; case 'U':printf("p[%d]=%c\n",i,p[i]); break; } } } main() { int a[20]; int n; n=sizeof(a)/sizeof(a[0]); input(a,n); vowles(a,n); }
run
|
edit
|
history
|
help
0
Lab 11 v1.0
C_141105_PuntosTriangulo
Nice1
Assignment 5 part 2
Project 3 Part 1 v2.1
Loop-worksharing
A_141201_MatrizTodosDistintos
HW22
Official Hello world
Code2