IGNOU Latest Assignments
IGNOU BCA Assignments BCA 2009
IGNOU BCA Assignments BCA 2008
IGNOU BCA Assignments BCA 2007
IGNOU BCA Assignments BCA 2006
IGNOU Latest Assignments
IGNOU BCA Assignments IGNOU BCA Assignments
IGNOU BCA Assignments IGNOU MCA Assignments
IGNOU MBA Assignmants IGNOU MBA Assignments

IGNOU > IGNOU Assignments > BCA > BCA 2006 Assignments > Introduction to System Software

IGNOU BCA Assignments

Question 1: Write an algorithm and draw a corresponding flow chart to convert a decimal number to its hexadecimal equivalent.


Ans:

Step 1: Take a input of decimal number.

Step 2: Now for converting decimal no into hexadecimal no. we start loop for process

Step 3: Loop start from no. and go at the 0.
Ex: While ($no – ne 0)

Step 4: Now find the remand by mod no by 10.
R= ‘expr $no % 10’

Step 5: Now check the remainder when remainder will be less then 10 that will be stored as it is.

Step 6: When remainder will be greater than equal to 10 that will be stored as alphabets as-

10 – A
11 – B
12 – C
13 – D
14 – E
15 –F

Step 7: Now short the number by divide 10.
Ex: no – ‘expr $no / 10’

Step 8: Repeat the step-4 through step-7 until number will be 0.

Step 9: After that print the hexadecimal no.

Step 10: Stop run.

Flow chart



PREVIOUSINDEXNEXT