CS作业代写 CS 115 DrRacket

CS 115 DrRacket
define, and, or, not, cond, else, check-expect, check-within
any type predicate such as number?, boolean?
any functions on numbers found in Section 1.5 of the Racket documentation any functions on symbols found in Section 1.7 of the Racket documentation any functions on strings found in Section 1.11 of the Racket documentation

Copyright By PowCoder代写 加微信 powcoder

I’J#0$K*L:05&’8:*
Look through the list of allowable built-in functions linked from above. You might find some handy functions that were not explicitly mentioned in the modules! All test data for correctness will always meet the stated assumptions for consumed values.

C87E-?DE$.60*-?+$L-04+$-L$P*D$S67*5$/G*+7J$2/$2*88$?+/$7E/$L-88-2*5D$0?8/+#
1. Words of two letters or less simply have “way” added on the end. So “go” becomes “goway”.
2. In any word of three or more letters that starts with consonants, the consonants are moved to the end, and “ay” is added. But if it begins with more than two consonants, move only the first two letters to the end. So “hello” becomes “ellohay”, and “string” becomes “ringstay”.
3. Any word which begins with a vowel simply has “way” added on the end. So “explain” becomes “explainway”.
“0*7/$6$L?5,7*-5$pig-latinB$M7$,-5+?4/+$6$+70*5DJ$65F$H0-F?,/+$7E67$+70*5D$,-5./07/F$7-$P*D$S67*5J$L-88-2*5D$7E/$0?8/+$F/+,0*Y/F$6Y-./B$3E/$+70*5D$+E688$,-576*5$-58Q$8-2/0,6+/$8/77/0+$65F E6./$6$8/5D7E$-L$67$8/6+7$’B
_-0$/G64H8/#
> (pig-latin “this”)
> (pig-latin “is”)
> (pig-latin “a”)
> (pig-latin “crazy”)
> (pig-latin “exercise”)
“exerciseway”

If a decimal point is used, the number must be represented with 2 decimal places.
If the number can be expressed exactly without cents, the string should not include a decimal point.
_-0$/G64H8/J$
> (encode-currency 42)
> (encode-currency 42.5)
> (encode-currency 420000)
$,-00/+H-5F*5D$5?4Y/0B$_-0$/G64H8/#
> (decode-currency “42”)
> (decode-currency “2.50”)
> (decode-currency “2,19”)
> (decode-currency “21,000.45”)
> (decode-currency “765.432,10”)
&6./$Q-?0$F/T5*7*-5+$*5$6$T8/$,688/F$a03q3.rkt$65F$+?Y4*7$*7$7-$d60K!+B )*+,?++*-5
Topic: Assignments / Assignment 3
Show all posts
2*0.’3*+45++*”6 /00’%’1″+(
by recent activity
Hi, I am aware that the assignment deadline has passed, however a question did come to mind about question 3 of the assignment. Since decimals and commas can be intercha…
? Contract
Hi, I noticed in module 4 section 4.4 when a “Requires:” was used, and there were more than one requirement, there was a use of * before every requirement. However, when I c…
& Whitespace Marking
Would it be possible to receive more guidelines about proper whitespace and indentation etiquette? After reviewing my marks of assignment 2 I lost several marks on illogical w…

? Allowable functions
Hi, Can we use (equal?) ? Thanks,
Hi, Just some clarification for question three. The question states that Q3 uses the same conventions as Q2, however in the example (decode-currency “765.432,10”). We see h…
? Question for Q1
is there any other efficient way to check whether or not a part of the string is a consonant/vowel other than using “equal?” and going through all the different consonants and v…
? Question 2
Should we consider cases where the decimal value is zero, or in this case two zeroes? ex. 45.00
? Question 3
In order to convert the string to a number, I’m using the str ∈ g → νmber function. However, this only works for integers. Otherwise, it returns it as a mixed fraction. Thus, I then u…
? Question 3
Hi, I was just wondering if we can assume that the string value will have just 2 decimal places?
Do we have to account for the possibility of decimal places **and** commas like in question three? so 10000.5 would turn into 10,000.50 in question two?
? Q3 Separator Clarification
Should our code be able to convert numbers in the thousands with the decimal separator and no cents? For example, 12000 expressed as 12.000. Or will we only see this conve…
? Allowed Functions
Are we allowed to use functions that utilize characters? For example, I want to use the built-in function string-ref and it produces a character type. It is in Section 1.11 which is o…
? How many examples we need?
HI i’m wondering how many examples we need for each question? Would 2 examples be enough?
? Question 2

程序代写 CS代考 加微信: powcoder QQ: 1823890830 Email: powcoder@163.com