SlideShare ist ein Scribd-Unternehmen logo
1 von 1
Downloaden Sie, um offline zu lesen
Building on the Student and course classes from a previous lab, implement the drop_student ()
instance method in the Course class, which removes a student (by last name) from the course
roster. If the student is not found in the course roster, no student should be dropped. The file
main.py will contain both the Student class and the Course class. Copy your student class from
the previous lab, or write a Student class with the following instance methods: - A Student
constructor that takes parameters for self, first, last, and gpa and sets the instance variables - A
method get_first(self) - return student's first name - A method get_last(self) - return student's last
name - A method get_gpa(self) - return student's gpa Ex: If a new Student object is created with
Andrew, Woo, 3.6, the default return values are: Andrew Woo 3.6 Copy your Course class from
the previous lab (you do NOT need the print statements), or write a Course class with the
following instance methods:

Weitere Àhnliche Inhalte

Ähnlich wie Building on the Student and course classes from a previous lab, imple.pdf

import school.; import school.courses.;public class Main { p.pdf
import school.; import school.courses.;public class Main { p.pdfimport school.; import school.courses.;public class Main { p.pdf
import school.; import school.courses.;public class Main { p.pdf
annaiwatertreatment
 
Java Basic day-2
Java Basic day-2Java Basic day-2
Java Basic day-2
Kamlesh Singh
 

Ähnlich wie Building on the Student and course classes from a previous lab, imple.pdf (8)

import school.; import school.courses.;public class Main { p.pdf
import school.; import school.courses.;public class Main { p.pdfimport school.; import school.courses.;public class Main { p.pdf
import school.; import school.courses.;public class Main { p.pdf
 
Java Inheritance
Java InheritanceJava Inheritance
Java Inheritance
 
Java abstract class & abstract methods
Java abstract class & abstract methodsJava abstract class & abstract methods
Java abstract class & abstract methods
 
CMSC 350 HOMEWORK 1
CMSC 350 HOMEWORK 1CMSC 350 HOMEWORK 1
CMSC 350 HOMEWORK 1
 
Method overloading, recursion, passing and returning objects from method, new...
Method overloading, recursion, passing and returning objects from method, new...Method overloading, recursion, passing and returning objects from method, new...
Method overloading, recursion, passing and returning objects from method, new...
 
Object Oriented Programming in PHP
Object Oriented Programming  in PHPObject Oriented Programming  in PHP
Object Oriented Programming in PHP
 
Python unit 3 m.sc cs
Python unit 3 m.sc csPython unit 3 m.sc cs
Python unit 3 m.sc cs
 
Java Basic day-2
Java Basic day-2Java Basic day-2
Java Basic day-2
 

Mehr von sattarali527

Calculate the gross income.At any time during 2019, did you receiv.pdf
 Calculate the gross income.At any time during 2019, did you receiv.pdf Calculate the gross income.At any time during 2019, did you receiv.pdf
Calculate the gross income.At any time during 2019, did you receiv.pdf
sattarali527
 

Mehr von sattarali527 (20)

CAM plants cope with hot, dry environments by Separating CO2 intake f.pdf
 CAM plants cope with hot, dry environments by Separating CO2 intake f.pdf CAM plants cope with hot, dry environments by Separating CO2 intake f.pdf
CAM plants cope with hot, dry environments by Separating CO2 intake f.pdf
 
Consider a humid temperate region such as western Oregon and Washingt.pdf
 Consider a humid temperate region such as western Oregon and Washingt.pdf Consider a humid temperate region such as western Oregon and Washingt.pdf
Consider a humid temperate region such as western Oregon and Washingt.pdf
 
Consider a cubic polynomial regression of Y on X (with no other varia.pdf
 Consider a cubic polynomial regression of Y on X (with no other varia.pdf Consider a cubic polynomial regression of Y on X (with no other varia.pdf
Consider a cubic polynomial regression of Y on X (with no other varia.pdf
 
conpelline wor. Peave eloberate the yatenent, identity the diferent .pdf
 conpelline wor. Peave eloberate the yatenent, identity the diferent .pdf conpelline wor. Peave eloberate the yatenent, identity the diferent .pdf
conpelline wor. Peave eloberate the yatenent, identity the diferent .pdf
 
concerning the companys operations in July appear below The company.pdf
 concerning the companys operations in July appear below The company.pdf concerning the companys operations in July appear below The company.pdf
concerning the companys operations in July appear below The company.pdf
 
Calculate the gross income.At any time during 2019, did you receiv.pdf
 Calculate the gross income.At any time during 2019, did you receiv.pdf Calculate the gross income.At any time during 2019, did you receiv.pdf
Calculate the gross income.At any time during 2019, did you receiv.pdf
 
Computer information systems - Tell us about your knowledge of a Coll.pdf
 Computer information systems - Tell us about your knowledge of a Coll.pdf Computer information systems - Tell us about your knowledge of a Coll.pdf
Computer information systems - Tell us about your knowledge of a Coll.pdf
 
Computer Model Specs For drawing the component layout diagram. Skyte.pdf
 Computer Model Specs For drawing the component layout diagram. Skyte.pdf Computer Model Specs For drawing the component layout diagram. Skyte.pdf
Computer Model Specs For drawing the component layout diagram. Skyte.pdf
 
COMPUTE FOR YOUR BASIC EARNING PER SHARE BASIC EARNINGS PER SHARE E.pdf
 COMPUTE FOR YOUR BASIC EARNING PER SHARE  BASIC EARNINGS PER SHARE E.pdf COMPUTE FOR YOUR BASIC EARNING PER SHARE  BASIC EARNINGS PER SHARE E.pdf
COMPUTE FOR YOUR BASIC EARNING PER SHARE BASIC EARNINGS PER SHARE E.pdf
 
Compuse the cash paybock periad for DO ITt 12.1 (LO 1), AP Wayne Com.pdf
 Compuse the cash paybock periad for  DO ITt 12.1 (LO 1), AP Wayne Com.pdf Compuse the cash paybock periad for  DO ITt 12.1 (LO 1), AP Wayne Com.pdf
Compuse the cash paybock periad for DO ITt 12.1 (LO 1), AP Wayne Com.pdf
 
Complete the MainActivity kt and MyAdapter kt code given below. Use t.pdf
 Complete the MainActivity kt and MyAdapter kt code given below. Use t.pdf Complete the MainActivity kt and MyAdapter kt code given below. Use t.pdf
Complete the MainActivity kt and MyAdapter kt code given below. Use t.pdf
 
Complete the following probability distribution table and then calcul.pdf
 Complete the following probability distribution table and then calcul.pdf Complete the following probability distribution table and then calcul.pdf
Complete the following probability distribution table and then calcul.pdf
 
Complete la tabla marcando () la columna correcta para cada afirma.pdf
 Complete la tabla marcando () la columna correcta para cada afirma.pdf Complete la tabla marcando () la columna correcta para cada afirma.pdf
Complete la tabla marcando () la columna correcta para cada afirma.pdf
 
Compare and contrast the changing roles of gametophytes and sporophyt.pdf
 Compare and contrast the changing roles of gametophytes and sporophyt.pdf Compare and contrast the changing roles of gametophytes and sporophyt.pdf
Compare and contrast the changing roles of gametophytes and sporophyt.pdf
 
Choose the climate forcings or feedbacks that cause climate anomalies.pdf
 Choose the climate forcings or feedbacks that cause climate anomalies.pdf Choose the climate forcings or feedbacks that cause climate anomalies.pdf
Choose the climate forcings or feedbacks that cause climate anomalies.pdf
 
Comparative balance sheets for Softech Canvas Goods for 2021 and 2020.pdf
 Comparative balance sheets for Softech Canvas Goods for 2021 and 2020.pdf Comparative balance sheets for Softech Canvas Goods for 2021 and 2020.pdf
Comparative balance sheets for Softech Canvas Goods for 2021 and 2020.pdf
 
Chose the answer that best describes the DNA genome replication mecha.pdf
 Chose the answer that best describes the DNA genome replication mecha.pdf Chose the answer that best describes the DNA genome replication mecha.pdf
Chose the answer that best describes the DNA genome replication mecha.pdf
 
Choose ALL the statements which are FALSE about DNA replication. a. O.pdf
 Choose ALL the statements which are FALSE about DNA replication. a. O.pdf Choose ALL the statements which are FALSE about DNA replication. a. O.pdf
Choose ALL the statements which are FALSE about DNA replication. a. O.pdf
 
Claim Fewer than 94 of adults have a cell phone. In a reputable pol.pdf
 Claim Fewer than 94 of adults have a cell phone. In a reputable pol.pdf Claim Fewer than 94 of adults have a cell phone. In a reputable pol.pdf
Claim Fewer than 94 of adults have a cell phone. In a reputable pol.pdf
 
Cick the icon to vew ino dsta the a) Find a 954 confidence interval f.pdf
 Cick the icon to vew ino dsta the a) Find a 954 confidence interval f.pdf Cick the icon to vew ino dsta the a) Find a 954 confidence interval f.pdf
Cick the icon to vew ino dsta the a) Find a 954 confidence interval f.pdf
 

KĂŒrzlich hochgeladen

Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
ciinovamais
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
QucHHunhnh
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
QucHHunhnh
 

KĂŒrzlich hochgeladen (20)

Micro-Scholarship, What it is, How can it help me.pdf
Micro-Scholarship, What it is, How can it help me.pdfMicro-Scholarship, What it is, How can it help me.pdf
Micro-Scholarship, What it is, How can it help me.pdf
 
Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptx
 
FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024
 
ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17
 
Application orientated numerical on hev.ppt
Application orientated numerical on hev.pptApplication orientated numerical on hev.ppt
Application orientated numerical on hev.ppt
 
Dyslexia AI Workshop for Slideshare.pptx
Dyslexia AI Workshop for Slideshare.pptxDyslexia AI Workshop for Slideshare.pptx
Dyslexia AI Workshop for Slideshare.pptx
 
Google Gemini An AI Revolution in Education.pptx
Google Gemini An AI Revolution in Education.pptxGoogle Gemini An AI Revolution in Education.pptx
Google Gemini An AI Revolution in Education.pptx
 
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdfUGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
 
HMCS Max Bernays Pre-Deployment Brief (May 2024).pptx
HMCS Max Bernays Pre-Deployment Brief (May 2024).pptxHMCS Max Bernays Pre-Deployment Brief (May 2024).pptx
HMCS Max Bernays Pre-Deployment Brief (May 2024).pptx
 
How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17
 
Making communications land - Are they received and understood as intended? we...
Making communications land - Are they received and understood as intended? we...Making communications land - Are they received and understood as intended? we...
Making communications land - Are they received and understood as intended? we...
 
Sociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning ExhibitSociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning Exhibit
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
 
Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and Modifications
 

Building on the Student and course classes from a previous lab, imple.pdf

  • 1. Building on the Student and course classes from a previous lab, implement the drop_student () instance method in the Course class, which removes a student (by last name) from the course roster. If the student is not found in the course roster, no student should be dropped. The file main.py will contain both the Student class and the Course class. Copy your student class from the previous lab, or write a Student class with the following instance methods: - A Student constructor that takes parameters for self, first, last, and gpa and sets the instance variables - A method get_first(self) - return student's first name - A method get_last(self) - return student's last name - A method get_gpa(self) - return student's gpa Ex: If a new Student object is created with Andrew, Woo, 3.6, the default return values are: Andrew Woo 3.6 Copy your Course class from the previous lab (you do NOT need the print statements), or write a Course class with the following instance methods: