Magpie/Chatbot Activity 5

Slides:



Advertisements
Similar presentations
Intro to GPS – Exercise 1, Navigating The GPS guides you to a destination using a GOTO (GOTO means GOing TO a destination in a direct line). Now use the.
Advertisements

Mrs. Chapman. Tabs (Block Categories) Commands Available to use Script Area where you type your code Sprite Stage All sprites in this project.
Slides prepared by Rose Williams, Binghamton University Chapter 14 Generics and the ArrayList Class.
Big Projects  Part of this class is about picking a cool software project and building it 1.
Mr. Wortzman. Tabs (Block Categories) Available Blocks Script Area Sprite Stage All sprites in this project.
1 L07SoftwareDevelopmentMethod.pptCMSC 104, Version 8/06 Software Development Method Topics l Software Development Life Cycle Reading l Section 1.4 – 1.5.
Advance Computer Programming Java Database Connectivity (JDBC) – In order to connect a Java application to a database, you need to use a JDBC driver. –
1 - buttons Click “Step Forward” to execute one line of the program. Click “Reset” to start over. “Play,” “Stop,” and “Step Back” are disabled in this.
Greenfoot. Getting Started Open the Greenfoot download site: Select Greenfoot
CHAPTER 1: INTRODUCTION TO COMPUTER SCIENCE Introduction to Computer Science Using Ruby (c) 2012 Ophir Frieder et al.
Putting Applets into Web Pages.  Two things are involved in the process of putting applets onto web pages ◦ The.class files of the applet ◦ The html.
Abstraction IS 101Y/CMSC 101 Computational Thinking and Design Tuesday, September 17, 2013 Marie desJardins University of Maryland, Baltimore County.
Method Overriding Remember inheritance: when a child class inherits methods, variables, etc from a parent class. Example: public class Dictionary extends.
Programming Concept Chapter I Introduction to Java Programming.
به نام خدا تنظیم کننده : فرانه حدادی استاد : مهندس زمانیان تابستان 92.
 Building Networks. First Decisions  What do the nodes represent?  What do the edges represent?  Know this before doing anything with data!
TEST-1 6. Testing & Refactoring. TEST-2 How we create classes? We think about what a class must do We focus on its implementation We write fields We write.
Using UML, Patterns, and Java Object-Oriented Software Engineering Chapter 16, Methodologies: Putting it all together.
Microsoft Visual Basic 2005 BASICS Lesson 1 A First Look at Microsoft Visual Basic.
1 Legacy Code From Feathers, Ch 2 Steve Chenoweth, RHIT Right – Your basic Legacy, from Subaru, starting at $ 20,295, 24 city, 32 highway.
Sahar Mosleh California State University San MarcosPage 1 JavaScript Basic.
MA471 Fall 2003 Lecture 2. On With The Games Today we are going to watch each group play a couple of rounds of cards. We will go through the game slowly.
Software testing techniques Software testing techniques Object-oriented software testing Presentation on the seminar Kaunas University of Technology.
CPSC 873 John D. McGregor Session 9 Testing Vocabulary.
Learning goal: Students will be able to demonstrate a basic understanding of how to use a computer.
AP Java Enhancing the Chatbot. Natural Language Processing Note: What is Natural Language Processing? What are some of the opportunities? What are some.
1 Data Structures CSCI 132, Spring 2014 Lecture 1 Big Ideas in Data Structures Course website:
Object Orientated Programming in Perl Simulated Models of Termites.
Project CS 116 Section 4 Deadline 04/28 11:59PM Points: 12.
© A+ Computer Science - Magpie Magpie is a lab that focuses on classes, randomness, and Strings. This lab will make sure that you.
Collision Theory and Logic
EGR 2261 Unit 11 Pointers and Dynamic Variables
AP Java Enhancing the Chatbot.
© A+ Computer Science - Magpie Chatbot Lab © A+ Computer Science -
John D. McGregor Session 9 Testing Vocabulary
Chapter 1 Introduction to Java
Collision Theory and Logic
Object-oriented software testing
Modern Collections Classes
ECET 370 ASSIST Something Great/ecet370assist.com
John D. McGregor Session 9 Testing Vocabulary
ECET 370 Education for Service-- tutorialrank.com
Installing and Using MARIE
Subroutines Idea: useful code can be saved and re-used, with different data values Example: Our function to find the largest element of an array might.
JavaScript an introduction.
John D. McGregor Session 9 Testing Vocabulary
O.S Lecture 13 Virtual Memory.
TDD adoption plan 11/20/2018.
Command Line Arguments
AP Magpie Chatbox "If a computer could think, how could we tell?"
Pixels.
Multiple Selections (ELIF Statements)
Installing and Using MARIE
Coding Concepts (Basics)
Introduction to TouchDevelop
Modern Collections Classes
Topic 1: Problem Solving
Manipulating Pictures, Arrays, and Loops
AP Java Enhancing the Chatbot.
LMC Little Man Computer What do you know about LMC?
Computer Science 2 Hashing.
Installing and Using MARIE
Programming Control Structures with JavaScript Part 2
CS334: Logisim program lab6
int [] scores = new int [10];
Dry Run Fix it Write a program
Lab 2: Information Retrieval
A drag and drop exercise can be created using Word quite easily using tables, text boxes and ensuring the document is saved properly.
Introduction to Methods and Interfaces
Introduction to Computer Science and Object-Oriented Programming
Presentation transcript:

Magpie/Chatbot Activity 5

Chatty 5 Learning Objectives Be able to implement using an array to store and use random responses

Prepare Read over Activity 5: Arrays and the Magpie (Optional) from the Magpie Lab Student Guide. Have available: • the code for the Magpie5 (Assignments\MagpieProject\activity5) • the code for the MagpieRunner5 • a computer with your Java development tools

Change the name of the class to yourNameMagpie5 and turn it in. Chatbot Activity 5 Change the name of the class to yourNameMagpie5 and turn it in. Exploration Run this version of the Magpie class. You should see no difference in its outward behavior. Instead, it has been changed so that its internal structure is different. This is called code refactoring. That’s one of the big benefits of dealing with methods as black boxes. As long as they perform the action required, the user does not care about how they perform the action. Read the code for getRandomResponse. Notice that it uses an array of responses. Exercise Alter the array to add four additional random responses. Notice that, because the getRandomResponse method uses the length attribute of the array, you do not need to change anything else. Compile and run your code. You should run it until you see all of your new responses.