Page 92 - Touhpad Ai
P. 92

b.  count = 0
                         for i in range(1, 6):
                             if i % 2 == 0:
                                 count += 1
                             else:
                                 count += 2
                        print(count)
                        c.  a = 3
                         b = 4
                         for i in range(1, 4):
                             if a > b:
                                 a -= 1
                             elif a < b:
                                 b -= 1
                             else:
                                 a += 1
                        print(a, b)
                     2.   Try shadow puppetry with a little help from AI: https://shadowart.withgoogle.com















                     3.     Play the binary game. For this, Scan the QR code or visit the link: https://learningcontent.
                         cisco.com/games/binary/index.html.
                         Toggle the bits to equal the number to the right. Which level could you reach?





















                  Answers
                Exercise
                A.  1. c.   2. d.   3. b.   4. b.   5. b.   6. c.   7. c.   8. b.   9. a.   10. c.   11. d.   12. b.
                B.  1. Decisions    2. Deployment     3. Textual, Numeric   4. NAND               5. Binary
                    6. Token     7. Instructions      8. String            9. start, step         10. pop()
                C.  1. True      2. False             3. False             4. True                5. False
                    6. False     7. True              8. True              9. False               10. True


                 90     Touchpad Artificial Intelligence - XI
   87   88   89   90   91   92   93   94   95   96   97