Velocity Reviews > programming, in c,

# programming, in c,

vinay
Guest
Posts: n/a

 03-29-2006
1.)write a function power(a,b), to calculate the value of a raised to

b.
2 .)write a general purpose function to convert any given year into
its roman equivalent.The following table shows the roman equivalents
of decimal integers.
Decimal Roman
1 i
5 v
10 x
50 l
100 c
500 d
1000 m
example : roman equivalent for 1988 is mdcccclxxxviii
roman equivalent of 1525 is mdxxv

jawaab dijiye

Guest
Posts: n/a

 03-29-2006

vinay wrote:
> 1.)write a function power(a,b), to calculate the value of a raised to b.

#include <math.h>

double power(double a, double b)
{
return pow(a,b);
}

> 2 .)write a general purpose function to convert any given year into

<snip homework assignment>

The first one you get for free, as a taster. For the other one, we can
arrange direct delivery to your teacher, if you provide us with their
e-mail address, and a cheque for one day's consulting fees, at a rate
to be negotiated.

--

alergh
Guest
Posts: n/a

 03-29-2006
Hi everybody,
do you know how can I find a process-ID, and stop it in C!

Thanks

Vladimir S. Oka schrieb:

> vinay wrote:
> > 1.)write a function power(a,b), to calculate the value of a raised to b.

>
> #include <math.h>
>
> double power(double a, double b)
> {
> return pow(a,b);
> }
>
> > 2 .)write a general purpose function to convert any given year into

>
> <snip homework assignment>
>
> The first one you get for free, as a taster. For the other one, we can
> arrange direct delivery to your teacher, if you provide us with their
> e-mail address, and a cheque for one day's consulting fees, at a rate
> to be negotiated.
>
> --

Guest
Posts: n/a

 03-29-2006

alergh wrote:

Do not top-post! Do not hijak threads!

Also, read, and heed:

<http://clc-wiki.net/wiki/Introduction_to_comp.lang.c>

before posting again.

> Hi everybody,
> do you know how can I find a process-ID, and stop it in C!

Standard ISO/ANSI C knows not of processes. Ask in group discussing

--

osmium
Guest
Posts: n/a

 03-29-2006
"vinay" writes:

> 2 .)write a general purpose function to convert any given year into
> its roman equivalent.The following table shows the roman equivalents
> of decimal integers.
> Decimal Roman
> 1 i
> 5 v
> 10 x
> 50 l
> 100 c
> 500 d
> 1000 m
> example : roman equivalent for 1988 is mdcccclxxxviii
> roman equivalent of 1525 is mdxxv

Anyone who converted Roman numbers and came up with that first example
would be fed to the lions. That is not a proper Roman number, it is your
instructor's vague notion of what a Roman number is.

jaysome
Guest
Posts: n/a

 03-30-2006
osmium wrote:

> "vinay" writes:
>
>
>>2 .)write a general purpose function to convert any given year into
>>its roman equivalent.The following table shows the roman equivalents
>>of decimal integers.
>>Decimal Roman
>>1 i
>>5 v
>>10 x
>>50 l
>>100 c
>>500 d
>>1000 m
>>example : roman equivalent for 1988 is mdcccclxxxviii
>>roman equivalent of 1525 is mdxxv

>
>
> Anyone who converted Roman numbers and came up with that first example
> would be fed to the lions.

LOL

.. That is not a proper Roman number, it is your
> instructor's vague notion of what a Roman number is.

Keith Thompson
Guest
Posts: n/a

 03-30-2006
jaysome <(E-Mail Removed)> writes:
> osmium wrote:
>
>> "vinay" writes:
>>
>>>2 .)write a general purpose function to convert any given year into
>>>its roman equivalent.The following table shows the roman equivalents
>>>of decimal integers.
>>>Decimal Roman
>>>1 i
>>>5 v
>>>10 x
>>>50 l
>>>100 c
>>>500 d
>>>1000 m
>>>example : roman equivalent for 1988 is mdcccclxxxviii
>>>roman equivalent of 1525 is mdxxv

>> Anyone who converted Roman numbers and came up with that first
>> example would be fed to the lions.

>
> LOL
>
> . That is not a proper Roman number, it is your
>> instructor's vague notion of what a Roman number is.

>

1988 in Roman numerals is mcmlxxxviii, not mdcccclxxxviii.

--
Keith Thompson (The_Other_Keith) http://www.velocityreviews.com/forums/(E-Mail Removed) <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <*> <http://users.sdsc.edu/~kst>
We must do something. This is something. Therefore, we must do this.

Richard Bos
Guest
Posts: n/a

 03-30-2006
Keith Thompson <(E-Mail Removed)> wrote:

> jaysome <(E-Mail Removed)> writes:
> > osmium wrote:
> >
> >> "vinay" writes:
> >>
> >>>example : roman equivalent for 1988 is mdcccclxxxviii
> >>>roman equivalent of 1525 is mdxxv
> >> Anyone who converted Roman numbers and came up with that first
> >> example would be fed to the lions.

> > . That is not a proper Roman number, it is your
> >> instructor's vague notion of what a Roman number is.

> >
> > Please explain.

>
> 1988 in Roman numerals is mcmlxxxviii, not mdcccclxxxviii.

QVOQVE CREDO ROMANI NON IAM HABENT LITTERAE CAROLINGIAE

VVLGO 1988 LATINE MCMLXXXVIII EST

Richard

Tony Quinn
Guest
Posts: n/a

 03-30-2006
In message <VIMWf.508\$(E-Mail Removed)>, jaysome <(E-Mail Removed)>
writes
>osmium wrote:
>
>> "vinay" writes:
>>
>>>2 .)write a general purpose function to convert any given year into
>>>its roman equivalent.The following table shows the roman equivalents
>>>of decimal integers.
>>>Decimal Roman
>>>1 i
>>>5 v
>>>10 x
>>>50 l
>>>100 c
>>>500 d
>>>1000 m
>>>example : roman equivalent for 1988 is mdcccclxxxviii
>>>roman equivalent of 1525 is mdxxv

>> Anyone who converted Roman numbers and came up with that first
>>example would be fed to the lions.

>
>LOL
>
>. That is not a proper Roman number, it is your
>> instructor's vague notion of what a Roman number is.

>

1988 is MCMLXXXVIII
--
A: Because it messes up the order in which people normally read text.
Q: Why is it such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?

Walter Roberson
Guest
Posts: n/a

 03-30-2006
In article <(E-Mail Removed)>,
Keith Thompson <(E-Mail Removed)> wrote:

>1988 in Roman numerals is mcmlxxxviii, not mdcccclxxxviii.

http://mathworld.wolfram.com/RomanNumerals.html

Furthermore, the practice of placing smaller digits before large
ones to indicate subtraction of value was hardly ever used by
Romans and came into popularity in Europe after the invention of
the printing press (Wells 1986, p. 60; Cajori 1993, p. 31).
[...]
It should also be noted that the Romans themselves never wrote M
for 1000, but instead wrote (I) for 1000, (I)(I) for 2000, etc.,
and also occasionally wrote IM, IIM, etc. (Menninger 1992, p. 281;
Cajori 1993, p. 32).
--
All is vanity. -- Ecclesiastes