Advertisement
backlight0815

Untitled

Jun 14th, 2022
152
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.63 KB | None | 0 0
  1. class Grade {
  2. let name: String
  3. var marks: Int
  4. var CGPA: String
  5. var grade: String
  6.  
  7. init(name: String, marks: Int, CGPA: String, grade: String){
  8. self.name = name
  9. self.marks = marks
  10. self.CGPA = CGPA
  11. self.grade = grade
  12. }
  13.  
  14. func Result(){
  15. marks -=0
  16. if marks >= 80 {
  17. print("Your")
  18. }
  19. }
  20.  
  21.  
  22. class Student: Grade {
  23. let level: String
  24. var CreditValue: Int
  25.  
  26. init(level: String, CreditValue: Int, name: String, marks: Int, CGPA: String,grade: String){
  27. self.level = level
  28. self.CreditValue = CreditValue
  29. super.init(name:name, marks:marks, CGPA:CGPA, grade:grade)
  30. }
  31. }
  32.  
  33. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement