<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.6000.16809" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face="Courier New" size=2>Almost right, but you did not yet test it.
You are close, though! Introduction of function quess is a good idea. The first
two cond lines have bugs. The procedure wont run correctly. After you have
made it working (which requires a few keystrokes only), you may want to avoid
calling procedure guess twice with the same arguments. But first make it
working after your present idea, then simplify.</FONT></DIV>
<DIV><FONT face="Courier New" size=2>Jos</FONT></DIV>
<BLOCKQUOTE
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV
style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
<A title=adityashukla1983@gmail.com
href="mailto:adityashukla1983@gmail.com">aditya shukla</A> </DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=grettke@acm.org
href="mailto:grettke@acm.org">Grant Rettke</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Cc:</B> <A title=plt-scheme@list.cs.brown.edu
href="mailto:plt-scheme@list.cs.brown.edu">PLT Scheme ML</A> ; <A
title=plt-edu-discuss@list.cs.brown.edu
href="mailto:plt-edu-discuss@list.cs.brown.edu">plt-edu-discuss@list.cs.brown.edu</A>
</DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Tuesday, February 17, 2009 8:19
PM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> Re: [plt-scheme] Combining
digits to form numbers</DIV>
<DIV><BR></DIV>This how i solved this problem .I have made another procedure
for guess thinking that the number returned by it depends on lsb , csb and
msb.Therefore it should be another procedure.<BR><BR>(define check-guess3
(lambda(lsb csb msb
target)<BR>
(cond<BR>
[(< guess(lsb csb msb) target)
'Toosmall]<BR>
[(= guess(lsb csb msb) target)
'Perfect]<BR>
[else 'Toolarge])))<BR>(define guess (lambda (lsb csb
msb)<BR>
(+(* msb 100)(* csb 10) (* lsb 1))))<BR><BR><BR><BR>Aditya<BR><BR><BR>
<P>
<HR>
<P></P>_________________________________________________<BR> For
list-related administrative tasks:<BR>
http://list.cs.brown.edu/mailman/listinfo/plt-scheme<BR></BLOCKQUOTE></BODY></HTML>