Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //
- // main.c
- // Falling Desks
- //
- // Created by Ahmed Fahmy on 4/22/19.
- // Copyright © 2019 Ahmed Fahmy. All rights reserved.
- //
- #include <stdio.h>
- #include "limits.h"
- int main(int argc, const char * argv[]) {
- // insert code here...
- // const int n = 1e6 +9;
- // const int m = 1e6 +9;
- int A[200000];
- int B[200000];
- //A is the array of the well contains the diameter values in top-down order
- //B is the array of the entered disks contains the diameter of disks values in dropping order
- //N the well disks number
- //M the rings number
- int i=0, j=0, N, M;
- printf("Please enter the Well Deep in meters : ");
- scanf("%ld",&N);
- printf("Please enter the number of the Disks dropped : ");
- scanf("%ld",&M);
- printf("Please assign the diameter of each concrete rings respectively in top-down order : ");
- for (i=0; i<N; ++i)
- scanf ("%ld",&A[i]);
- printf("Please assign the diameter of each concrete Disk respectively in they are to be dropped : ");
- for (j=0; j<M; ++j)
- scanf ("%ld",&B[j]);
- int r,s;
- for(r=0; r<N ; ++r) printf("%ld",A[r]);
- for(s=0; s<N ; ++s) printf("%ld",B[s]);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement