All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > General
Ages (Posted on 2004-08-31) Difficulty: 2 of 5
A man and his grandson have the same birthday. For six consecutive years, the man's age was a exact multiple of the boy's age. How old were they at the last birthday?

See The Solution Submitted by Federico Kereki    
Rating: 3.0000 (7 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution chart | Comment 4 of 10 |

A table looks nice:

   2222222222333333333344444444445555555555666666666677777777778
   0123456789012345678901234567890123456789012345678901234567890
 1 *************************************************************
 2 *.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*
 3 .*..*..*..*..*..*..*..*..*..*..*..*..*..*..*..*..*..*..*..*..
 4 *...*...*...*...*...*...*...*...*...*...*...*...*...*...*...*
 5 *....*....*....*....*....*....*....*....*....*....*....*....*
 6 ....*.....*.....*.....*.....*.....*.....*.....*.....*.....*..
 7 .*......*......*......*......*......*......*......*......*...
 8 ....*.......*.......*.......*.......*.......*.......*.......*
 9 .......*........*........*........*........*........*........
10 *.........*.........*.........*.........*.........*.........*
11 ..*..........*..........*..........*..........*..........*...
12 ....*...........*...........*...........*...........*........
13 ......*............*............*............*............*..
14 ........*.............*.............*.............*..........
15 ..........*..............*..............*..............*.....

with a nice diagonal starting at 1,61 going to 6,66.

PRINT "   ";
FOR a = 20 TO 80
  PRINT LEFT$(LTRIM$(STR$(a)), 1);
NEXT
PRINT
PRINT "   ";
FOR a = 20 TO 80
  PRINT RIGHT$(LTRIM$(STR$(a)), 1);
NEXT
PRINT

FOR i = 1 TO 15
  PRINT USING "## "; i;
  FOR m = 20 TO 80
   IF m / i = INT(m / i) THEN PRINT "*"; :  ELSE PRINT ".";
  NEXT
  PRINT
NEXT

 

Edited on August 31, 2004, 10:31 am
  Posted by Charlie on 2004-08-31 10:27:05

Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (3)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2024 by Animus Pactum Consulting. All rights reserved. Privacy Information