decrement

decrement

how do we start a program with C++.....a program that decrements from 225 to 0!!!!

View Answers

September 13, 2012 at 10:29 AM

Here is a C++ progrma that decrements the number from 225 to 0.

 #include <iostream>
    using namespace std;
    int main() {
    int i=225;
    while(i>=0) {
    cout << i << endl;
    i--;
    }
    return 0;
    }









Related Tutorials/Questions & Answers:
decrement
PHP Increment Decrement Operator
of increment and decrement, much like C,C++. but in few cases it follows Perl style... decrement value of a is:".--$a."<br/>";ADS_TO_REPLACE_3 echo "Post decrement value of a is:".$a--."<br/>"
Advertisements
time decrement
Auto Increment and Decrement
Auto Increment and Decrement   ... decrement operator and display the value on the console and then applying the postfix decrement operator and displaying the value on the console
servlet session - JSP-Servlet
the counter if new user logs on and decrement if session times out or user  Hi... on and decrement if session times out or user log offs.Thanks
PHP Mathematical Operation
, increment, decrement etc. Example 1:ADS_TO_REPLACE_1 <?php $a=25; $b...;; echo "<br/> Before Decrement value of \$b is=$b";ADS_TO_REPLACE_6 $b--; echo "<br/> After Decrement value of \$b
JavaSwing
JavaSwing  I create 4 text box and 3 buttons.button1 is using increment option and button2 using decrement option button3 using reset option.when i click the button1 the value will be increase and the result is shown
Subtract a value in the database from java
Subtract a value in the database from java   Hi, i want to know how to subtract a value on a database. im using JDBC connection from access and i want to decrement the value of table "quantity" of 1 each time it passes a loop my
Description
increment the value of j by decrement the value of n. The third loop provides the incremented space. The fourth loop first decrement the value of j
Description
increment the value of j by decrement the value of n. The third loop provides the incremented space. The fourth loop first decrement the value of j
Description
increment the value of j by decrement the value of n. The third loop provides the incremented space. The fourth loop first decrement the value of j
Description
increment the value of j by decrement the value of n. The third loop provides the incremented space. The fourth loop first decrement the value of j
Java For loop Iterator
Iterator can be used with the for loop also. Initialization of the Iterator is done before the for loop. Iterator has boolean value with the hasNext method. So no increment/decrement is required. Java for Loop Iterator
retain count in Objective C
increment and decrement the counter as per requirement. See an example
what is retain count in objective c
easily increment and decrement the counter as per requirement. See an example
Looping Statements in java 7
and increment/decrement. Syntax:ADS_TO_REPLACE_2 for(initialization; Boolean termination; increment/decrement) {....... ...... //Statements } initialization..._TO_REPLACE_3 increment/decrement : If condition is true then your variable either
For Loop Statement in java 7
/Termination Increment/Decrement Initialization : In this phase of for loop we.... Increment/Decrement : It is your iteration part, you can increment or decrement loop variable which changes the value of variable so that it meets
help with program - Java Beginners
;*");//Print *System.out.println();b-=2;//Decrement b by 2}//end of loop
PHP For Loop
: to check the validity of the condition, Increment/Decrement: we can increment or decrement the variable(s). Format of for loop is as below:ADS_TO_REPLACE_1 for(variable initialization; condition; variable increment/decrement
WRITE A PROGRAM IN JAVA
WRITE A PROGRAM IN JAVA  How do I write a program in Java, have the program display a message with your name in it and a number (Hello john Smith!1) The number must increment from zero to nine, or decrement fron nine to zero. You
PHP For Loop Function
: to check the validity of the condition, Increment/Decrement: we can increment or decrement the variable(s). For loop function Example:ADS_TO_REPLACE_1
Java Applet - Adding a Button to Decrease a Total
and decrement the integer value. There are two buttons in an applet for increment and decrement respectively. On clicking these button, value will get incremented
Arithmetic Operators
++ 4 * Multiplication y=3 y*3 9 -- Decrement
Objective-c memory management: retain and release
object so that programmer can easily increment and decrement the counter as per...;, [myClassObj2 retainCount]); // Decrement their counts
PHP FORM Part-7
is :  for (initialize the value; condition/endvalue; increment/decrement... of the loop.   3. Increment and Decrement ExpressionADS_TO_REPLACE_13 Every loops required a number of series to increment or decrement the value
Java Programming Implement a virtual print queue
records: q,3,10 is a q type record which indicates that a print job, # 3, shall... of execution from last to first. A print job will decrement the number of remaining
Operators
; Increment operator; increments a value by 1 --   Decrement
JSP Session Counter Using SessionListener
. In HttpSessionListener we can implement a counter every time a session is created and decrement
Operators
; Increment operator; increments a value by 1 --   Decrement
Operators
; Increment operator; increments a value by 1 --   Decrement
Operators
; Increment operator; increments a value by 1 --   Decrement
Operators
; Increment operator; increments a value by 1 --   Decrement
Synchronized Threads
.  Suppose, we have created two methods as increment( ) and decrement( ). which...; count++;   }   public void decrement... for increment( ),another for decrement( )) then both will share the variable "
Unary Operators
;  --    Decrement operator  decrements... (++) and Decrement OperatorsADS_TO_REPLACE_3 The increment/decrement operators can
Synchronized Threads
.  Suppose, we have created two methods as increment( ) and decrement( ). which...; count++;   }   public void decrement... for increment( ),another for decrement( )) then both will share the variable "
Synchronized Threads
.  Suppose, we have created two methods as increment( ) and decrement( ). which...; count++;   }   public void decrement... for increment( ),another for decrement( )) then both will share the variable "
Java Control Statements
; for (initialization; condition; increment or decrement){   <statement>...; increment or decrement: After each iteration, value increments or decrements
Java Tutorial
. Increment Operator : '++' Decrement Operator : '--' Ternary Operator.../decrement; do....while loop : do....while loop is same as while loop
Operators In Java
. These operations can be increment/decrement, invert a boolean value, etc.  ... that increments the value of numeric operand by 1.   -- : This is a unary decrement
php Operators
Increment ++ let $x=2 ++$x 3 Decrement -- let $y=5 --$y 4
Java Control Statement
; increment or decrement) { //statement; } 2. The while loop : A while loop
Java Training and Tutorials, Core Java Training
and Decrement Operators:   
Beginners Java Tutorial
; Auto Increment and Decrement In this example we are demonstrating

Ads