How to accept numbers frm users using arrays and printing the 4th power of the number and store it in another array and print it | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

How to accept numbers frm users using arrays and printing the 4th power of the number and store it in another array and print it

very important question

22nd Nov 2016, 8:04 PM
Piyush Bisht
3 Answers
+ 1
//edited C code snippet below : int main { int size, num, i; int original[1000] ; long long power4[1000] ; scanf("%d", & size) ; for ( i=0;i<size;i++) { scanf ("%d", &num) ; original[i] = num; power4[i] = (num*num*num*num) ; printf ("%lld \n", power4[i]) ; } printf("Done! Printed and stored in power4 array") ; return 0; }
22nd Nov 2016, 8:12 PM
StAn
StAn - avatar
0
thankyou but how to do it using c
22nd Nov 2016, 8:13 PM
Piyush Bisht
0
Check it out now. It is in C now. Give it a thumbs up, bro. :p
22nd Nov 2016, 8:17 PM
StAn
StAn - avatar