Search Interview Questions | More than 3000 questions in repository. There are more than 900 unanswered questions. Click here and help us by providing the answer. Have a video suggestion. Click Correct / Improve and please let us know. |
|
| ||||
Interview Questions and Answers | ||||
| ||||
Ans. We can select the appropriate Price Class if that suits us. We can do Geo Targeting by black listing / white listing certain geographies. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  aws cloudfront  amazon cloudfront | ||||
| ||||
Ans. If the computation required is Spiky and unpredictable. If it's first time use. If the lifespan of the application isn't known. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  aws ec2  aws computing  amazon cloud computing  amazon ec2 | ||||
| ||||
Ans. If the usage is non continuous and have flexible start and End Time. For ex - Analysis , Research , mining etc. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  aws ec2  aws computing  amazon cloud computing  amazon ec2 spot | ||||
| ||||
Ans. On Demand Reserved Spot Dedicated Host | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  aws ec2  aws computing  amazon cloud computing  amazon ec2 | ||||
| ||||
Ans. Keeping Low cost for processing , i would choose Spot Price Plan F1 or P3 Instance Type Cold Hdd (SCI ) EBS Volume | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  aws ec2  aws computing  amazon cloud computing  amazon ec2 | ||||
| ||||
Ans. Computation Spot Price Plan F1 or P3 Instance Type Cold Hdd (SCI ) EBS Volume Storage S3-IA | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  aws computation  aws ec2  aws computing  amazon cloud computing  amazon ec2 | ||||
| ||||
Ans. We can assign multiple security groups to single instance and we can use single security group with multiple instances. It never results in conflict as security groups only have allow rules and no deny rules. Multiple security groups for an instance results in union of all rules. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  aws ec2  aws computing  amazon cloud computing  amazon ec2  aws security group | ||||
| ||||
Ans. No, We can do that through ACL | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  aws security group | ||||
| ||||
Ans. S3 is object based whereas EFS is block based. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  aws s3  aws storage  amazon cloud storage  amazon s3  aws efs | ||||
| ||||
Ans. Firstly ,we have removed old backup data from server after that we are checking which user consume high memory through df command. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  server  Amazon Web Service (AWS)  production support Asked in 1 Companies | ||||
| ||||
Ans. An object's lock is a mechanism that is used by multiple threads to obtain synchronized access to the object. A thread may execute a synchronized method of an object only after it has acquired the object's lock. All objects and classes have locks. A class's lock is acquired on the class's Class object. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  java   threads   multi threading   scheduling   synchronizing | ||||
| ||||
Ans. JSON is "JavaScript Object Notation", primarily used for client-server or server-server communication. Its a much lighter and readable alternative to XML. JSON is language independent and is easily parse-able in all programming languages. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  json   markup language   client server communication Asked in 26 Companies basic   frequent | ||||
Try 2 Question(s) Test | ||||
| ||||
Ans. JSON.stringify() turns an object into a JSON text and stores that JSON text in a string. So If we stringfy above notation , it will become {"name":"xyz","gender":"male";"age":30} | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  json   JSON.stringify intermediate   rare | ||||
| ||||
Ans. Enums were introduced with java 5. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  java5   enum | ||||
Try 1 Question(s) Test | ||||
| ||||
Ans. eval | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  json   markup language | ||||
| ||||
Ans. Number String Boolean Array Object null | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  json   markup language   client server communication | ||||
| ||||
Ans. An API is a kind of technical contract which defines functionality that two parties must provide: a service provider (often called an implementation) and an application. an API simply defines services that a service provider (i.e., the implementation) makes available to applications. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  j2ee   api   java basic   frequent | ||||
| ||||
Ans. URL is Uniform Resource Locator which is representation of HTTP address. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  j2ee   http   internet   url basic   rare | ||||
| ||||
Ans. HTTP or Hypertext Transfer Protocol is internet protocol for tranmission of hypertext ( text with meta data ) over internet. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  j2ee   http   internet  fidelity Asked in 2 Companies basic   frequent | ||||
| ||||
Ans. Tomcat is a web server and a Servlet container. It is often used as an application server for web-based applications but does not include the complete suite of capabilities that a Java EE application server would supply. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  tomcat   j2ee   web server   application server   build management | ||||
| ||||
Ans. boolean ---> false byte ----> 0 short ----> 0 int -----> 0 long ------> 0l char -----> /u0000 float ------> 0.0f double ----> 0.0d any object reference ----> null | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  java   data types   default values | ||||
Try 1 Question(s) Test | ||||
| ||||
Ans. One can import the same package or same class multiple times. Neither compiler nor JVM complains wil complain about it. And the JVM will internally load the class only once no matter how many times you import the same class. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  java   import   jvm   advanced Asked in 1 Companies intermediate   rare | ||||
| ||||
Ans. For top level class we can only use "public" and "default". We can use private with inner class. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  java   class   access specifier   inner classes basic   frequent | ||||
| ||||
Ans. An asynchronous event is one that occurs at an unpredictable time outside the control of the program that the CPU is running. It is not "synchronized" with the program. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  j2ee   internet   web application   asynchronus   asynchronus communication   architecture Asked in 1 Companies | ||||
| ||||
Ans. Suppose that a software group traditionally starts the body of every class with comments providing important information: public class Generation3List extends Generation2List { // Author: John Doe // Date: 3/17/2002 // Current revision: 6 // Last modified: 4/12/2004 // By: Jane Doe // Reviewers: Alice, Bill, Cindy // class code goes here } To add this same metadata with an annotation, you must first define the annotation type. The syntax for doing this is: @interface ClassPreamble { String author(); String date(); int currentRevision() default 1; String lastModified() default "N/A"; String lastModifiedBy() default "N/A"; // Note use of array String[] reviewers(); } The annotation type definition looks similar to an interface definition where the keyword interface is preceded by the at sign (@) (@ = AT, as in annotation type). Annotation types are a form of interface, which will be covered in a later lesson. For the moment, you do not need to understand interfaces. The body of the previous annotation definition contains annotation type element declarations, which look a lot like methods. Note that they can define optional default values. After the annotation type is defined, you can use annotations of that type, with the values filled in, like this: @ClassPreamble ( author = "John Doe", date = "3/17/2002", currentRevision = 6, lastModified = "4/12/2004", lastModifiedBy = "Jane Doe", // Note array notation reviewers = {"Alice", "Bob", "Cindy"} ) public class Generation3List extends Generation2List { // class code goes here } | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  java   annotations | ||||
| ||||
Ans. @Deprecated annotation indicates that the marked element is deprecated and should no longer be used. The compiler generates a warning whenever a program uses a method, class, or field with the @Deprecated annotation. @Override annotation informs the compiler that the element is meant to override an element declared in a superclass. @SuppressWarnings annotation tells the compiler to suppress specific warnings that it would otherwise generate. @SafeVarargs annotation, when applied to a method or constructor, asserts that the code does not perform potentially unsafe operations on its varargsparameter. When this annotation type is used, unchecked warnings relating to varargs usage are suppressed. @FunctionalInterface annotation, introduced in Java SE 8, indicates that the type declaration is intended to be a functional interface, as defined by the Java Language Specification. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  java   java8   annotations   pre defined annotations | ||||
| ||||
Ans. Annotations that apply to other annotations are called meta-annotations. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  java   annotations   meta annotations | ||||
| ||||
Ans. @Retention annotation specifies how the marked annotation is stored: @Documented annotation indicates that whenever the specified annotation is used those elements should be documented using the Javadoc tool. (By default, annotations are not included in Javadoc.) @Target annotation marks another annotation to restrict what kind of Java elements the annotation can be applied to. @Inherited annotation indicates that the annotation type can be inherited from the super class. (This is not true by default.) When the user queries the annotation type and the class has no annotation for this type, the class' superclass is queried for the annotation type. This annotation applies only to class declarations. @Repeatable annotation, introduced in Java SE 8, indicates that the marked annotation can be applied more than once to the same declaration or type use. For more information, see Repeating Annotations. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  java   java8   annotations   meta annotations | ||||
| ||||
Ans. To display the current CLASSPATH variable, use these commands in UNIX (Bourne shell): % echo $CLASSPATH To delete the current contents of the CLASSPATH variable, In UNIX: % unset CLASSPATH; export CLASSPATH To set the CLASSPATH variable, In UNIX: % CLASSPATH=/home/george/java/classes; export CLASSPATH | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  unix   unix commands   classpath | ||||
| ||||
Ans. Threads in Java can be implement either by Extending Thread class or implementing runnable interface. | ||||
Help us improve. Please let us know the company, where you were asked this question : | ||||
Like Discuss Correct / Improve  java   threads   multi threading Asked in 1 Companies basic   frequent | ||||