Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Lab 9 v0.9
//gcc 5.4.0 #include <stdio.h> #include <string.h> int main(void){ int n=4; int m=4; int ca=0; int cb=0; int ci=0; int c=0; char A[4]={'a','b','c','d',}; char B[4]={'c','d','e','f',}; //char U[30]; char I[30]; //n=sizeof(A)/4; //m=sizeof(B)/4; char U[n+m]; printf("%d=n+m\n",n+m); for(int g=0;g<n+m;g++){ if(g<n){ U[c]=A[ca]; printf("U[%d]=%c\n",c,U[c]); ca++; c++; } else if(g>=n){ for(int d;d<n;d++){ if(B[cb]!=A[d]){ U[c]=B[cb]; printf("U[%d]=%c\n",c,U[c]); cb++; c++; } else{ cb++; } } } } printf("\n\n"); for(int i=0;i<=n;i++){ for(int j=0;j<=n;j++){ if(A[i]==B[j]){ I[ci]=A[i]; printf("I[%d]=%c\n",ci,I[ci]); ci++; } } } printf("\n\n"); }
run
|
edit
|
history
|
help
0
141128_EjemploChorraArray
C_141113_VariosPerfectos
18BCE2182 ASSESS_1 Q2-2
Score
pointer**
lab8part2final
Quadratic Formula
funcion quicksort
C141106_TablaMultiplicar
DUE BY TUESDAY