2034 Views

How can we construct an increment statement or decrement stmt in c lang and what do they do


My_ goodness 20th Oct, 2020
Answer (1)
NAVYA BOINPALLY Student Expert 20th Oct, 2020

Hi,

We can do this in two different ways.

1) By using the increment operator ++ and the decrement operator.

for example, the statement "i+=" means to increment the value of x by 1. Like, The statement "x-" means to decrement the value of x by 1.

2) The 2nd way of writing increment statements is to use the conventional + (plus sign) or minus sign. In this case "i++", another way to write it is "i=i+1

Hopefully this information is helpful.

Thank you.

Related Questions

CLAT Current Affairs with GK ...
Apply
Stay updated with current affairs & check your preparation with the CLAT General Knowledge Mock Tests Ebook
CLAT English Language Mock Tests
Apply
Free Ebook - CLAT 2025 English Language questions with detailed solutions
ICFAI Business School-IBSAT 2024
Apply
9 IBS Campuses | Scholarships Worth Rs 10 CR
CLAT Legal Reasoning Mock Tests
Apply
Free Ebook - CLAT 2025 legal reasoning questions with detailed solutions
GIBS Business School Bangalor...
Apply
100% Placements with 220+ Companies
Great Lakes PGPM & PGDM 2025
Apply
Admissions Open | Globally Recognized by AACSB (US) & AMBA (UK) | 17.3 LPA Avg. CTC for PGPM 2024
View All Application Forms

Download the Careers360 App on your Android phone

Regular exam updates, QnA, Predictors, College Applications & E-books now on your Mobile

150M+ Students
30,000+ Colleges
500+ Exams
1500+ E-books