O'Reilly logo

Learn to Program with C by Noel Kalicharan

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 2

image

C – The Basics

In this chapter, we will explain the following:

  • What is an alphabet, a character set, and a token
  • What is a syntax rule and a syntax error
  • What is a reserved word
  • How to create identifiers in C
  • What is a symbolic constant
  • The C data types—int, float, and double
  • How to write int and double expressions
  • How to print an integer using a field width
  • How to print a floating-point number to a required number of decimal places
  • What happens when int and double values are mixed in the same expression
  • What happens when we assign int to double and double to int
  • How to declare a variable to hold a string
  • How to assign a string value ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required