Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Write a program that takes a 5 digit number and calculates
2 power that number and prints it

Answer Posted / s.sivarajan

question :
Write a program that takes a 5 digit number and calculates
2 power that number and prints it

answer:

that question ask the exponential.
In the compute clause we use the ** for exponential
so write a program using this.

example:

IDENTIFICATION DIVISION.
PROGRAM-ID. SIVARAJAN.
ENVIRONMENT DIVISION.
DATA DIVISION.
WORKING-STORAGE SECTION.
01 A PIC 9(10) VALUE 2.
01 B PIC 9(10) VALUE 12345.
01 EXP PIC 9(25).
PROCEDURE DIVISION.
START-PARA.
COMPUTE EXP=A**B.
DISPLAY EXP.
STOP RUN.

Is This Answer Correct ?    5 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the newline escape sequence?

1019


What is the difference between variable declaration and variable definition in c?

1013


What is operator promotion?

1011


how to find anagram without using string functions using only loops in c programming

3128


What is array of structure in c?

1093


Is linux written in c?

986


What is anagram in c?

869


Do variables need to be initialized?

989


What do you mean by dynamic memory allocation in c?

1044


Can we declare variables anywhere in c?

946


What is sizeof in c?

952


Is c language still used?

932


What are the 3 types of structures?

977


How do you write a program which produces its own source code as output?

1055


How to declare a variable?

954