CP104 Lecture Notes - Lecture 8: Substring
hayjayshay and 38575 others unlocked
2
CP104 Full Course Notes
Verified Note
2 documents
Document Summary
Built-in functions (quotient x y) ignores the remainder x = bigger number, y = divisor; (remainder x y) Can be used to compare 2 values which are not of the same type. = can compare 2 or more values, as long as they are numerical (append lista listb listc) combines the lists together only when the first list isn"t empty (length listname) gives length of the list. Member consumes an element of any type and a list, and returns true if the element appears in list. Determines if it is a string (char<=?) compares alphabetical order spaces, punctuation, digits, upper-case, lower-case. Comparison becomes case-insensitive, as if lower and uppercase letters were the same. Char-downcase / char-upcase changes the character to their lower/upper versions, but does not change if a character is already in that case, or if it"s not a letter (space, number, punctuation) Built-in structures (define-struct name (field 1 field2 field3))