[Updated] Goldman Sachs Aptitude Test Questions and Answers
Practice List of TCS Digital Coding Questions !!!
Take 50+ FREE!! Online Data Interpretation Mock test to crack any Exams.

C Programming :: Input / Output - Discussion

Home > C Programming > Input / Output > MCQs Questions Discussion

4 / 6

Choose the correct option.

if i,j,k are integers, the scanf function to enter i,j,k such that i is decimal,j is octal and k is hexadecimal would be

Ascanf("%x %x %8x",i,j,k)

Bscanf("%d %o %x", i,j,k)

Cscanf("%d %o %x",&i, &j, &k)

Dscanf("%d %8d %16d", &i, &j, &k)

Answer: Option (Login/Signup)

Show Explanation

1. %d- to scan an integer value.

2. %o- to scan an octal value.

3. %x- to scan value in hexadecimal format.

 

Asked In ::

Post Your Answer Here:     

Reply    
Rate This: +0 -0
    Report


Report Error

Please Login First Click Here