What is the java source filename extension

Assignment Help JAVA Programming
Reference no: EM13690075

Answer the following questions in detail.

Question 1: What is the Java source filename extension? What is the Java bytecode filename extension?

Question 2: Write a Java statement to display the string The value is 100 to a user in a plain dialog box.

Question 3: What is the command you would use to compile the file Addition.java?

Question 4: What is the command you would use to execute the Addition class?

Question 5: What does a Java class contain that identifies it as a Java application?

Question 6: Write a Java statement that declares a constant called MAX which has a value of 1000.

Question 7: How do C++ chars differ from Java chars?

Question 8: Given a double variable called dval, write a single Java statement to prompt the user to enter the price of an item using JOptionPanes, convert the result and store it into dval.

Question 9: Write one Java statement to display the string “The average is xxx” to the console, where the xxx displays the value from the double variable sum divided by 3. Make sure the value is displayed with 3 digits following the decimal point.

Question 10: Write one Java statement to create a string containing The average is where the xxx contains the formatted value from the double variable sum divided by 3. Make sure the formatted string contains only 2 digits following the decimal point. Store the formatted string into a String variable called str.

Question 11: Explain the difference between an object reference in Java and an object. Use an example to illustrate your answer.

Question 12: Explain how objects are created in Java and how the memory used by objects is recovered. Compare this to object creation and destruction in C++.

Question 13: Explain how primitive values like doubles are passed between functions in Java. How are string objects passed between functions in Java?

Question 14: How are static methods different from non-static methods? How do you invoke a static method? Give an example of a static method.

Question 15: Write an expression that returns a random value between 1 and 100. The values 1 and 100 must be included in the values that can be returned.

Question 16: Write one Java statement that creates an array of 100 doubles.

Question 17: Write one Java statement that creates an array of integers containing the multiples of 10 between 10 and 100, including 10 and 100.

Question 18: Write one Java statement that would take an array A and copy its contents into array B. Assume that A and B already exist and that B is at least as large as A and that they are both of the same data type.

Question 19: Write a Java method which takes an integer array parameter and locates the minimum value in the array and outputs that value using System.out.printf. Use an enhanced for loop to process the array. You only need one loop to do this!

Question 20: Write a Java method which takes an integer array parameter and fills the array with random numbers between 1 and 1000, including 1 and 1000. Use a traditional for loop to process the array.

Solve this problem using java programming concepts.

Reference no: EM13690075

Questions Cloud

What is the percent ionization of solution of this acid : Problem- The Ka of a monoprotic weak acid is 3.38 Ã- 10-3. What is the percent ionization of a 0.149 M solution of this acid
Convert the hexadecimal numbers to binary : Convert the following hexadecimal numbers to binary, then add them togather (assume you have an 8 bit processor that uses 2' compliment representation). : -
Why embedded system processor would use concurrent processes : Explain why embedded system processor would use concurrent processes to control an alarm system in a home. Door and Window switches, motion detector all controlled through a central panel.
How many moles of calcium fluoride is produced : Problem- When 0.54 moles of CaCO3 are put in a reaction vessel with plenty of aluminum fluoride, how many moles of calcium fluoride is produced
What is the java source filename extension : What is the Java source filename extension? What is the Java bytecode filename extension and write a Java statement to display the string The value is 100 to a user in a plain dialog box.
Write a balanced equation for the reaction : Problem- Ethyl acetate reacts with H2 in the presence of a catalyst to yield ethyl alcohol- C4 H8O2(l) +H2(g)-------> C2H6O6(l) Part a) Write a balanced equation for the reaction.
Calculate the ph of a solution made by mixing equal volumes : Problem- Calculate the pH of a solution made by mixing equal volumes of a solution of HCl with a pH of 1.44 and a solution of HNO3 with a pH of 2.74. Assume the volumes are additive
Application which tests the random number generation : Write a Java application that inputs three integers from the user and displays the sum, average, product, smallest and largest of the numbers.
How many moles of cac2o4 are present in this kidney stone : Problem- The principal component of many kidney stones is calcium oxalate, CaC2O4. A kidney stone recovered from a typical patient contains 8.5 x 10^20 formula units of calcium oxalate. How many moles of CaC2O4 are present in this kidney stone

Reviews

Write a Review

JAVA Programming Questions & Answers

  Build a graphical user interface for displaying the image

Build a graphical user interface for displaying the image groups (= cluster) in JMJRST. Design and implement using a Swing interface.

  Design an object-oriented java application

You are to design an object-oriented Java application to let the user play a dice game that uses two dices. The player bets on a value and the dices roll

  Huge integer class

Huge Integer Class) Create a class HugeInteger which uses a 40-element array of digits to store integers as large as 40 digits each. Provide methods parse, toString, add and subtract. Method parse should receive a String, extract each digit using met..

  What was in mind of the coder in each part of the code

Need a video that goes through all this java code - as if it was a tutorial showing it line by line - and explain in detail the structure of it all as if you code it yourself.

  Use data structures and algorithm to implement search engine

For the URLs in the keyword list, sort them by either the number of times the keyword appearing in the pages or the popularity of the pages.

  Create an application that will allow a new customer

Create an application that will allow a new customer to order a house. You'll allow the customer to choose among four models (Aspen, Britattany, Colonial, and Dartmoor) by creating separate ButtonGroups.

  Application that simulates a cash register

Implement a graphical application that simulates a cash register. Provide a text field for the item price and two buttons for adding the item to the sale, one for taxable items and one for nontaxable items. In a text area, display the register tap..

  Write a java program that reads a five-line address

Write a Java program that reads a five-line address from an input file and produces an output file with the address repeated 50 times in three columns.

  Be sure to show all declarations

Write a function call that invokes function a. Be sure to show all declarations. However a complete main is not required.

  Client class to test implementation of the vector class

Write a client class to test your implementation of the Vector3D class thatyou implemented. Name the package in which this class is defined (projectname) vector3dapp.

  Statements to print a label

Add the statements to print a label in the following format (the numbers in the example output are correct for input of $4.25 per pound and 41 ounces). Use the formatting object money to print the unit price and total price and the formatting object ..

  Program mimics a rudimentary spreadsheet

Change the averages so that they are rounded to the nearest one hundredth. The example above shows averages in format - Change the program so that before the spreadsheet window is displayed, the user sees the window

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd