Need Help Programming Language C M Supposed Call Function Scanf Store Row Column Struct L Q37276462

Need help in Programming Language C ONLY

I’m supposed to… Call function scanf () to store the row andcolumn in struct Location target

the issue is I’m not sure how to proceed, so far i’m supposed todeclare a local variable which Is Locationtarget

What I have atm:

scanf(“%d %d”, &row, &col);


Answer


Location target;scanf(“%d %d”, &(target.row), &(target.col)); // assuming Location has variables row and col

;

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.