Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

C# Console app quick quiz

Status
Not open for further replies.

hmckillop

Programmer
Oct 30, 2001
1,540
GB
Hello,

I was recently asked this question, and just wanted to pose this to the forum to see what people think is the best solution - post your answers and we can judge on performance, elegance and coding skill.

Thanks

PS - when complete I will post my answer (which isnt the most elegant)

QUESTION:#
In a normal year, February has 28 days, April has 30 and January and May both have 31. Using letters for digits consistently, JAN and MAY are divisible by 31, APR is divisible by 30, and FEB is divisible by 28.

Create a program which uniquely identifies the three-digit number for FEB and writes it to the console screen.


So each letter stands for a single digit, there are ten distinct letters, each representing a unique digit between 0..9.

Thanks

"I'm living so far beyond my income that we may almost be said to be living apart
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top