Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <string.h>
- #include <math.h>
- char str[5000][5000];
- int main()
- {
- int t, i, j, k, l, a, b, c, d, x, y, z, sum, count, len, max;
- char str2[5000];
- j = 0, max = 0;
- for (; ;)
- {
- gets (str2);
- if (feof(stdin))
- break;
- len = strlen(str2);
- if (len >= max)
- {
- max = len;
- }
- strcpy(str[j], str2);
- str[j][len] = '\0';
- j++;
- }
- for (k = 0; k < max; k++)
- {
- for (l = j - 1; l >= 0; l--)
- {
- if ( (str[l][k] != '\0') && str[l][k] != ' ' )
- {
- printf("%c", str[l][k]);
- }
- }
- printf("\n");
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement