Search for notes by fellow students, in your own course and all over the country.

Browse our notes for titles which look like what you need, you can preview any of the notes via a sample of the contents. After you're happy these are the notes you're after simply pop them into your shopping cart.

My Basket

You have nothing in your shopping cart yet.

Title: C programming code : Change-Base-of-Number
Description: This PDF - there are 2 pages - C programming code about Change Base of Number - 67 line coding to change #1 base a become #2 base b

Document Preview

Extracts from the notes are below, to see the PDF you'll receive please use the links above


Change-Base-of-NumberU-130
...
h>
#include ...
c
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67 }

22/9/2556 19:08

{
pten=pten*10;
}
time++;
}while (x>=1);
pten=10;
while (time!=0)
{
Odegit=(Onumber%pten)/(pten/10);
Osum=Osum+(Odegit*Sbase);
pten=pten*10;
Sbase=Sbase*Obase;
time--;
}
while (NsumNsum=Nsum/Nbase;
printf("The new number of base %ld is ",Nbase);
do
{
Nnumber=Osum/Nsum;
Ndegit=Nnumber%Nbase;
if (Ndegit==14) printf("E");
else if (Ndegit==13) printf("D");
else if (Ndegit==12) printf("C");
else if (Ndegit==11) printf("B");
else if (Ndegit==10) printf("A");
else printf("%ld",Ndegit);
Nsum=Nsum/Nbase;
}
while (Nsum>=1);
printf("\n\n");

Page 2 of 2


Title: C programming code : Change-Base-of-Number
Description: This PDF - there are 2 pages - C programming code about Change Base of Number - 67 line coding to change #1 base a become #2 base b