Posts

Enumerated data types in c++

Enumerated data types Simple integer constants are required to represent domain specific data. For example, Colour of an automobile can be specified by a set of statements using cost qualifiers: Const int cRED =0; Const int cBLUE = 1; ……… Int auto_colour; Auto_colour=cBLUE; However, there are no checks. Since variable auto_colour is an integer, the following assignments are valid: auto_colour=-1; …….. auto_colour=rand(); Of course, these statements lose the semantics; variable auto_colour doesn’t any longer represent a colour, it is just an integer. It is thus important to be able to tell the compiler: “Variable auto_colour is supported to represented a colour, that is one of the defined set of choices RED, BLUE,…” and then have the compiler check, pretty thoroughly, that auto_colour is only used in this way throughout the program. This leads to “enumerated data types”. Enumerated data types are an alternative way of declaring a set of integer constant and definin

Java interview question answer

1. What is java? Java is a OOP based computer programming language.  2. Explain, what is the difference between private, protected, and public in java? These java keywords are for following privileges to component such as variables and methods. Public: All classes can be access Private: Can be access only the class to which belongs Protected: Can be access to the class to which they belongs and any subclasses. 3. What are access specifiers in java? Access specifiers are keywords that determine the type of access to the member of a class.  There are four types of specifiers in java (a) Public, (b) Private, (c) Protected, and (d) Defaults. 4. What's the difference between normal methods and constructors? Constructors cannot return a value and must have the same name as the class. Constructors are only called once while normal methods could be called many times and it can return a value or can be void (it is your choice).  5. It is possible to call on

SQL Basics And Advance

What is a database It is a coherent collection of data with some inherent meaning, built and populated with data for a specific purpose. A database stores data that is useful to us. This data is only a part of the entire data available in the world around us. To be able to successfully design and maintain database we have to do the following: Ø   Identify which part of the word’s data is of interest to us. Ø   Identify what specific objects in that part of the word’s data are of interest to us. Ø   Identify a relationship between the objects.   Software houses took up the challenge of designing a system that would help users in managing data in a database. These systems were called Database Management Systems (DBMS). Some of the DBMS developed by software houses were Oracle, Ingress, Sybase, etc. Let us look at Oracle as a Database Management System (DBMS). Introduction to Oracle and Its Tools: The Oracle product is primarily divided into   Oracle s