- Jestion 2 Object Oriented Programming Oop Is A Programming Paradigm Based On The Concept Of Objects Which Can Conta 1 (53.56 KiB) Viewed 28 times
JESTION 2 Object-oriented programming (OOP) is a programming paradigm based on the concept of "objects", which can conta
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am
JESTION 2 Object-oriented programming (OOP) is a programming paradigm based on the concept of "objects", which can conta
JESTION 2 Object-oriented programming (OOP) is a programming paradigm based on the concept of "objects", which can contain data and code: data in the form of fields, and code, in the form of procedures. There are 4 basics of OOP concepts which are abstraction, encapsulation, inheritance, and polymorphism. (i) Explain what is the difference between encapsulation and polymorphism? C2 [SP1] [2 marks] (ii) A temperature sensor is used to read a boiling tank temperature. When the reading is 100° Celsius and more, stove will turn off and valve will open to flow out the water. If the reading is below 100 Celsius, stove will turn on fire and valve will close. Write a Java program as simulation of the condition and user able to set their own value as temperature value to simulate it. C5 [SP4] [7 marks] (iii) Modify the Java program in Q2(a)(ii) to let user run random number of temperature value each time they run the simulation. Let the simulation automatically run for 5 times. C4 [SP3] [3 marks] Computer Interfacing often referred to a shared boundary across which two or more separate components of a computer system exchange information. The exchange can be between software, computer hardware, peripheral devices, humans, and combinations of these. (i) Describe how Android Studio Apps can interface with microcontroller through a Wi-Fi communication? C2 [SP1] [2 marks]