Constant , Basic Computer Science

Constant:

In contrast to a variable, which is used as identifier for a value and which can change, constants are identifiers that are used for values, which cannot be changed. In other words constants are symbols used to refer to quantities which do not change throughout the life of a program. No assignment can be done to a constant.  A numeric constant stands for a number.  This number can be an integer, a decimal fraction, or a number in scientific (exponential) notation. Some of the operations which can be performed with numeric constants are addition, subtraction, multiplication, division and comparison.   A string constant consists of a sequence of characters enclosed in double/single quote marks. Chopping off some of the characters from the beginning or end, adding another string at the end (concatenation), copying are some of the operations that performed on the string constants. All these operations can be done on variables also.   

Posted Date: 10/23/2012 3:46:06 AM | Location : United States







Related Discussions:- Constant , Assignment Help, Ask Question on Constant , Get Answer, Expert's Help, Constant Discussions

Write discussion on Constant
Your posts are moderated
Related Questions

Question 1 What is an operating system? Explain its functions Question 2 Discuss round-robin scheduling Question 3 Discuss on segmentation Question 4 What are the s

text graphics audio video

You can also allocate a single value to several variables at the same time. For instance: X=y=z =1 Now, an integer object is generated with the value 1, and all three variables are

how to start ms power point

i don''t understand how to create a program using double, int, float, short etc

Brief Define the Phases of Waterfall Model

Keyboards, microphones, and mice have generally been used as the standard input devices for most computer systems. The popularity of video and computer games has led to the introdu

Purpose of Code This is a short program to practice assembly language loops and if/else statements. You will use various jump commands and the cmp instruction.  The progra

2. Mike sells on the average 15 newspapers per week (Monday – Friday). Find the probability that 2.1 In a given week he will sell all the newspapers [7] 2.2 In a given day he w