delorie.com/archives/browse.cgi | search |
X-Authentication-Warning: | delorie.com: mail set sender to djgpp-bounces using -f |
From: | "Keith__" <asdth AT hotmail DOT com> |
Newsgroups: | comp.os.msdos.djgpp |
Subject: | newbie C question |
Date: | Mon, 24 Nov 2003 11:07:27 -0000 |
Lines: | 32 |
Message-ID: | <bpsopf$3ak$1@newsg1.svr.pol.co.uk> |
NNTP-Posting-Host: | 81.77.66.253 |
X-Trace: | newsg1.svr.pol.co.uk 1069672047 3412 81.77.66.253 (24 Nov 2003 11:07:27 GMT) |
NNTP-Posting-Date: | 24 Nov 2003 11:07:27 GMT |
X-Complaints-To: | abuse AT theplanet DOT net |
X-Priority: | 3 |
X-MSMail-Priority: | Normal |
X-Newsreader: | Microsoft Outlook Express 6.00.2800.1158 |
X-MimeOLE: | Produced By Microsoft MimeOLE V6.00.2800.1165 |
To: | djgpp AT delorie DOT com |
DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
Reply-To: | djgpp AT delorie DOT com |
Hi sorry to bother you all with this but im currently at college beginning to learn C. I have a question ive been given which i need to code and answer but i just dont understand what it wants or how to do it. could someone please help out? heres the question in full: 1. Read three single digit characters from the keyboard and convert them into their numerical equivalent values (Hint: use getchar(), subtract character zero from the digit character to convert it to its numerical value.) The program should test the digits and a) print an appropriate message if the digits are identical b) the average of the three digits c) the minimum of the three digits d) the maximum of the three digits e) the percentage value of the smaller number with respect to the larger. Thanx Keith
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |