Cashback Offer (20th - 30th September 2020). Get Flat 10% Cashback credited in your account on a minimum transaction of $80. Post Your Question

Question DetailsNormal
$ 20.00

Assignment 1 Q1.What do you understand by complier error and run time error? Explain by example.A++

Question posted by
Online Tutor Profile
request

Assignment 1

Due date: Saturday - October 3rd, 2015 at 11:59 PM.

Q1.What do you understand by complier error and run time error? Explain by example.
Note: Do not use the book example. [2 Points]

Q2. What is wrong with the following variable declarations? [1.5 Points]
int Km/h = 120;
String Newcar = GMC;
int Adouble = “50”;
String newCar = “GMC”
int x = 5, y = “x”;
String new Car = “GMC”;

Q3. What does this sequence of statements print? [1.5 Points]
String msg = “The number of characters in newCar is”;
String newCar = ”GMC”;
int numberOfCharacters = newCar.length();
String carUpperCase = newCar.toUpperCase();
System.out.print(newCar);
System.out.println(carUpperCase);
System.out.print(msg);
System.out.println(newCar.length());
newCar.replace(“C”,”U”);
newCar.replace(“M”,”E”);
newCar.replace(“G”,”S”);
System.out.print(“Welcome to : ”);
System.out.println(newCar);
/*System.out.println(“Good luck”);
System.out.println(“to all students”);*/

Q4. Consider the following class: [2 Points]
a. What are the instance variables?
b. What is the output from the following code:

Q5. What is the output of the following code: [2 Points]
a.
b.

Q6. Write a Java program that performs the following: [6 Points]
1. Identify the radius of the circle. (radius = 3)
2. Calculate circumference and area of the circle.
3. Print the results.
public class IdentifyMyParts
{
private int x = 7;
private int y = 3;
}
IdentifyMyParts a = new IdentifyMyParts();
IdentifyMyParts b = new IdentifyMyParts();
a.y = 5;
b.y = 6;
a.x = 1;
b.x = 2;
System.out.println("a.y = " + a.y);
System.out.println("b.y = " + b.y);
System.out.println("a.x = " + a.x);
System.out.println("b.x = " + b.x);
int num1 = 6;
int num2 = 10;
num1 = num1 + num2;
num2 = num1 + num2;
System.out.println(num1 + ", " + num2);
int a = 10;
int b = 20;
int c = 2;
int x = b / a /*c*/;

Available Answer
$ 20.00

[Solved] Assignment 1 Q1.What do you understand by complier error and run time error? Explain by example.A++

  • This solution is not purchased yet.
  • Submitted On 28 Sep, 2015 02:52:31
Answer posted by
Online Tutor Profile
solution
Answer 1: Compile time error is caused due to incorrect syntax. The program will not compile and complier will throw error if the syntax is inco...
Buy now to view the complete solution
Other Similar Questions
User Profile
QUIZL...

NURS 6640N Week 4 Assignment 1

For Solution Please download the enclosed Attachment. ...
User Profile
Kevin...

B6028 Module 4 Assignment 2 Internal Environmental Scan Organizational Assessment

Module 5 - M5 Assignment 2 Internal Environmental Scan/Organizational Assessment     Internal Environmental Scan/Organizational Assessment This section provides the opportunity to develop your course project. Conducting...
User Profile
Symone

Homework Assignment AA

Receive excel file too Homework Assignment AA all at 10 ...
User Profile
Symone

Homework Assignment AA

Kindly receive your completed Homework Assignment AA. There are two files namely word containing description and an excel file containing calculation of ratios...
User Image
quizh...

Homework Assignment 3

Employee Salary Department dep1 dep2 dep3 dep4 3 $32,782 1 $32,782 $35,467 $23,654 $65,487 8 $32,920 1 $32,920 $35,468 $36,578 $46,184 9 $29,548 1 $29,548 $29,876 $37,548 $54,899 18 $39,828 1 $39,828 $43,674 $53...

The benefits of buying study notes from CourseMerit

homeworkhelptime
Assurance Of Timely Delivery
We value your patience, and to ensure you always receive your homework help within the promised time, our dedicated team of tutors begins their work as soon as the request arrives.
tutoring
Best Price In The Market
All the services that are available on our page cost only a nominal amount of money. In fact, the prices are lower than the industry standards. You can always expect value for money from us.
tutorsupport
Uninterrupted 24/7 Support
Our customer support wing remains online 24x7 to provide you seamless assistance. Also, when you post a query or a request here, you can expect an immediate response from our side.
closebutton

$ 629.35