Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #define N 5
- int main(void) {
- int beki[N][N], i, j, k, tmp;
- for (i = 0; i < N; i++) {
- for (j = 0; j < N; j++) {
- tmp = i + 1;
- for (k = 0; k < j; k++) {
- tmp *= i + 1;
- }
- beki[i][j] = tmp;
- }
- }
- for (i = 0; i < N; i++) {
- for (j = 0 ; j < N; j++) {
- printf("% 5d ", beki[i][j]);
- }
- puts("");
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement