Write down the commonly used scanf format codes?

Commonly used scanf format codes: 

In the following table the required format codes and their meanings are given.

read a single character
read a decimal integer
read a floating point value
read a floating point value
read a floating point value
read a short integer
read decimal, hexadecimal or octal integer
read an octal integer
read a string
read an unsigned decimal integer
read a hexadecimal integer
read a string of word(s)

Author: Tanmay Chakrabarty

Tanmay Chakrabarty is a former CSE student, currently working as a Senior Software Engineer with 5+ years of experience in the field of Web Application development in PHP+MySQL platform with strong skills in Javascript, JQuery, JQuery UI and CSS. He tries to write notes every week but fails due to heavy loads of duty.

Recommended Recommends


Contact Us