answersLogoWhite

0

📱

Java Programming

The Java programming language was released in 1995 as a core component of the Java platform of Sun Microsystems. It is a general-purpose, class-based, object-oriented language that is widely used in application software and web applications.

5,203 Questions

What is mean by functions in oops?

Functions are used to carryon a specific task or to perform specific operation.

Where are the random numbers placed in slot machines?

While older slot machines used a mechanical/mathematical approach (the number of icons on each wheel, combined with the required combination of those to yield various winning matches), today's typical slot machine are completely computerized. They generate thousands of random combinations per second, and when you pull the handle (or push the button), the cycle stops and you get the number it was up to. The handle, the slowing-down of the wheels, etc., are there simply for historical purposes.

What is a single core ghz?

"Single core" refers to the computer's main chip having a single processor. Newer models, such as Intel's i3, i5 and i7, have multiple processors (2, 4, or 6 processors), usually called multiple "cores", on a single chip.

GHz refers to the clock speed of each individual processor. It gives you a rough idea of how fast it can process data. However, the processing speed will also depend on other factors.

How do you generate a random integer within a range in Java?

Take advantage of Java's easy-to-use Random class.

// Create a new Random object.

// The constructor accepts a single Long argument.

// This is the seed for the random generator.

// Using the current time is standard for most applications.

Random rnd = new Random(System.currentTimeMillis());

// A call to nextInt(n) will generate a random value from 0 to n-1

// This is typical in programming languages, and in order to get a specific range we need

// to tweak it a bit.

rnd.nextInt(n);

// This will give you a random int from (start) to (start + range - 1)

rnd.nextInt(range) + start;

Why is single thread system not used in java?

Because the developers of Java considered the possibility of multithreading a big advantage. You don't HAVE TO use multiple threads; just use it when you need it.

Because the developers of Java considered the possibility of multithreading a big advantage. You don't HAVE TO use multiple threads; just use it when you need it.

Because the developers of Java considered the possibility of multithreading a big advantage. You don't HAVE TO use multiple threads; just use it when you need it.

Because the developers of Java considered the possibility of multithreading a big advantage. You don't HAVE TO use multiple threads; just use it when you need it.

Which qualifier is used to declare read-only variable in java?

A variable declared as final can't be modified, once a value is assigned.

What is the difference between default constructor and parameterized constructor?

A default constructor is one that has no parameters (C++ also calls constructors with all default parameters a default constructor), while a parameterized constructor is one that has at least one parameter without a default value. Default constructors can be provided by the compiler if no other constructors are defined for that class or any class the class inherits from, while parameterized constructors must always be defined by the developer.

What is meant by private visibilty of a method?

It means that the method is visible from only within the current method. Also, any class that wants to use or invoke the private method has to create an object of the class in which the method is created in order to access/invoke it. The private access modifier is the most restrictive of the four java access modifiers. The total opposite of private is public which gives access to everyone.

What are the characteristic of good test cases?

  1. It should be simple and clear, any tester should be able to understand it reading once.
  2. Should be accurate and tests what it is intended to test.
  3. No unnecessary steps should be included.
  4. It should be reusable.
  5. It should be traceable to requirements.
  6. It should be independent. i.e. You should be able to execute it in any order without any dependency on other test cases.

What does import java.util.Scanner?

It is used import your scanner class. In other words bringing in the scanner class.

How do you disable a button in Java?

you can easily disable java in almost all of the web browsers! I just came across this article telling how to disable java in different browser, check this out :

http://studyabroadfree.com/how-to-disable-java-in-browsers-after-us-cert-warning/

How are the strings passed to a function?

By reference. The name of the string is converted to a pointer (in C/C++) and given to the function as the address of the first element. (In Java, all objects are passed by reference, and there are no pointers.)

What is Java byte-code level language?

Java byte-code is the code which generate after the compilation of .java file.And this code is only understand by JVM(java virtual machine ) which understand it and execute it.In other languages this type of functionality is not available.

What are the advantages of interface IN JAVA?

  • Interfaces are classes that help us in implementing partial Multiple Inheritance in Java.
  • It helps us in defining skeleton behavior for our classes.
  • Also, it is used for creating classes that store application level constants

Does Linux have java support?

Yes. Most operating systems have some form of Java for them.

What is shine enterprise java pattern?

Shine Enterprise Java PatternShine Enterprise Java Pattern has been developed for variety of application. This pattern has these parts:

Maplet: a framework for doing web projects which are coincidence with MVC architecture. This framework helps developers to follow a standard pattern for developing a web application. Maplet helps developers to save time of developing and extending.

JShooter: a framework that makes reflects oriented programming an easy job for developers. Meanwhile it helps distributing application on the network.

JConnection: This package helps developers to work with JDBC and Hibernate easier than before.

Util: This package helps developers in these subjects:

1- File System

2- Runtime

3- Compiler

4- System Information

5- Web Socket

6- MD5

7- Thread

8- Validation

9- XML Parsing

10- Web uploading

Maplet (Web, MVC Framework)

What is Maplet?

Maplet is a framework for implementing web based program, which is compatible with MVC architecture. This framework is very easy and helpful for developers and analyzers to do their jobs better than before.

JShooter (Reflect in Network Framework)

What is JShooter?

JShooter is a framework for distributing application programs on the network. Certainly, you have used RMI, Corba and JMS. Each of aforementioned technologies has its own special problems and at the same time enjoys extraordinary advantages. However, you must be careful about the expenses caused by these technologies. In most cases RMI, Corba and JMS increase the productions' costs unbelievably. However in other cases they confuse programmers. Years ago, Reflect Oriented Programming was the focus of attention within professional programmers, then Aspect Oriented Programming came into the programming world but instead of reducing the programmer's task, it causes the professional programmers and even the amateur ones to be confused in many cases. One of the most important capabilities of JShooter is that it makes the "Reflect Oriented Programming" easier to use.

JConnection (JDBC & Hibernate Component)

What is JConnection?

JConnection is a tool for developers at the DB layer that solve lots of amateurs' problems. This tool helps you to work with JDBC and Hibernate.

JDBC Class

This class helps you to less engagement with Statement and Connectionin entities in JDBC.

Hiberbate Class

This class makes it easy to work with Hibernate

What is Util?

Util package helps you to implement your application very easily. This package helps developers who don't want to use basic codes for their application.

What is Analyzer Class?

This class helps you to do XMLParsing easily.

What is Browser Class?

This class allows you to access the contents of a site via Web Socket.

What is Code class?

This class can considerably help you in encryption.

"addFileToWindowsRuntime", create a new class. Afterward you can create an object from the created class by using JShooter.

What is Info Class?

This class gives the user specifications from the executive system.

What is JCompiler?

This class considerably helps you to compile at the run time. For using it, you should inherit from the JCompiler class, then use the "addFileToWindowsRuntime", create a new class. Afterward you can create an object from the created class by using JShooter.

What is JThread class?

This class remarkably helps using Threads. The class that uses JThread class, must fist inherit from JThread.

What is JValidation Class?

This class helps in validations.

What is root class?

This class is designed for working with FileSystem.

What is run Class?

This class helps you using operation system commands in your application without considering the type of it.

What is normative method?

This is concerned with looking into the commonality of some elements. Best used with status study.

What is a CARE Package?

a box you get after 4 kills in a row. any items except emergency air drop nuke and care package.

What is class modifiers in java?

Class Modifiers are access modifiers that specify the accessibility levels of a class.

There are 4 basic access modifiers in java. They are:

1. Public

2. Protected

3. Default and

4. Private

Java programming does not run by just a single piece of class that has the whole functionality. You have hundreds of classes that interact with one another, passing data between them and returning output to the user of the system. So it is very important for members of one class to access members of another. Here members may refer to variables, methods and even classes. So, this is where the access modifiers come into picture. The modifier associated with every member of the class determines what level of visibility that member has.

How do you write a Java program to accept a 3-digits integer number and print out the highest digit from the derived input?

The tricky part is getting the individual digits. There are basically two ways to do this: 1) Convert the number to a string, and use string manipulation to get the individual digits. 2) Repeatedly divide the number by 10. The digit is the remainder (use the "%" operator).

To actually get the highest digit, initially assume that the highest digit is zero (store this to a variable, called "maxDigit" or something similar). If you find a higher digit, replace maxDigit by that.

Effect of assigning one object reference variable to another object reference variable?

In that case, both variables will point to the same object. Changes done through one object reference will also be visible if you access the object through the other object reference.

In that case, both variables will point to the same object. Changes done through one object reference will also be visible if you access the object through the other object reference.

In that case, both variables will point to the same object. Changes done through one object reference will also be visible if you access the object through the other object reference.

In that case, both variables will point to the same object. Changes done through one object reference will also be visible if you access the object through the other object reference.

A program prints vertically a numbers in c program?

It is too easy................

//Program to print numbers vertically

#include<stdio.h>

#include<conio.h>

void main()

{

int last_no;

int i;

clrscr();

i=0;

printf("Enter your last num.I will print 0 to that number");

scanf("%d",&last_no);

printf("\n");

while(i>last_no)

{

printf("%d\n",i);

i++;

}

getch();

}

//poo.papule

What is the difference between an interface and an abstract class?

We can't instantiate both interfaces and abstract classes.

The only one difference between them is that an interface can't contain concrete(fully defined) methods where as an abstract class may contain them.

An abstract class not necessarily contain abstract methods. we can make a class as abstract class even it does not has any abstract methods.

When there is a need to write both abstract and concrete methods in a single unit we have to use an abstract class instead of an interface since an interface cant contain concrete methods.

All the fields(or properties) of an interface are by default 'static final' even when you don't mention explicitly. And all methods are 'public abstract'.

But in an abstract class we can have any type of fields and methods.

What are the three looping statements in java PL?

There are 4 different looping statements in Java. They are:

  1. While loop
  2. Do-While loop
  3. For loop
  4. For Each loop