Nisuga Jayawardana

Administrators
  • Content Count

    11
  • Joined

  • Last visited

  • Days Won

    7

Nisuga Jayawardana last won the day on July 5

Nisuga Jayawardana had the most liked content!

Community Reputation

9 Neutral

About Nisuga Jayawardana

Recent Profile Visitors

246 profile views
  1. Nisuga Jayawardana

    You can access Previous Year2 Content here

    Version 1.0.0

    1 download

    This includes Year 2 content of 2018 which can help you understanding/learning 2019 Y2. https://drive.google.com/open?id=19-eSn6IkFjHFBRnFaeJ5_gjzDdMpjtc2
  2. Regular Registration Notice June- December 2019.pdf Find next semester start date on bottom of this PDF(Regular Registration Notice June- December 2019).
  3. Nisuga Jayawardana

    ITP tips and issues here

    Let's discuss ITP tips and issues here.
  4. CN_Lab Test 2 Q&A + 2016PP.zip
  5. Nisuga Jayawardana

    🔴 OSSA Lab Test Q&A

    ela
  6. Nisuga Jayawardana

    OOP Mock Exam Paper & Answers

    Mock Exam.pdf OOP Mock Exam Answers.pdf
  7. Find the answer in below PDF. Any suggestion regarding the answer is strongly appreciated. OOP_11b(NumberCalculation)_ANSWER.pdf OOP_11b Number Calculation import java.util.InputMismatchException; import java.util.Scanner; public class Computation { private int number1; private int number2; private int result; public Computation(int number1, int number2) { super(); this.number1 = number1; this.number2 = number2; } public void read(){ try { Scanner sc = new Scanner(System.in); System.out.println("Enter Number 1: "); number1 = sc.nextInt(); if(number1 < 30 || number1 > 80) { throw new NumberNotIn30AND80Exception(); } System.out.println("Enter Number 2: "); number2 = sc.nextInt(); if(number2 < 30 || number2 > 80) { throw new NumberNotIn30AND80Exception(); } } catch (InputMismatchException e) { System.out.println("Please enter only Numbers!!"); read(); } catch (NumberNotIn30AND80Exception e) { System.out.println("Please Enter a number between 30 AND 80 !!!"); read(); } } public void Substract() { result = number1 - number2; } public void Divide() { try { result = number1 / number2; } catch ( ArithmeticException e ) { System.out.println("Nothing can be divided by 0 !!!"); } } public int getResult() { return result; } } public class NumberNotIn30AND80Exception extends Exception{ public NumberNotIn30AND80Exception() { super(); } } ------------------------------------------------------------------------------------------------------------------------------------------------ public class CalcApp { public static void main(String[] args) { Computation comp1 = new Computation(42, 32); comp1.read();//Inserting 65 and 35 comp1.Substract(); // Result = 30 Computation comp2 = new Computation(comp1.getResult(), 2); comp2.Divide();// Result = 15 System.out.println("Result is: "+ comp2.getResult() ); } }
  8. Nisuga Jayawardana

    💻 OOP Online Test Q&A

    Answers for Clock question.OOP 06B.pdf
  9. Nisuga Jayawardana

    Augmented Reality is changing our world

    How Augmented Reality is changing our world — insights into how AR is transforming brands, businesses and industries https://medium.com/teamarimac/how-augmented-reality-is-changing-our-world-insights-into-how-ar-is-transforming-brands-619709ad0adc