Basic Syntax

When we consider a Java program, it can be defined as a collection of objects that communicate via invoking each other’s methods. Let us now briefly look into what do class, object, methods, and instance variables mean.

  • Object − Objects have states and behaviors. An object is an instance of a class.
  • Class − A class can be defined as a template/blueprint that describes the behavior/state that the object of its type supports.
  • Methods − A method is basically a behavior. A class can contain many methods. It is in methods where the logics are written, data is manipulated and all the actions are executed.
  • Instance Variables − Each object has its unique set of instance variables. An object’s state is created by the values assigned to these instance variables.

Example:

public class First

                     {

                           public static void main(String []args)

                           {

                                      System.out.println(“Hello World!!!”);

                           }

                        }

Output:

      Hello World!!!

Read More

Data set

The application stays connected to the DB system even when it is not using DB services. This commonly wastes valuable and expensive database resources, as most of the time applications only query and view the persistent data. ADO.Net solves this problem by managing a local buffer of persistent data called data set. 
Our application automatically connects to the database server when it needs to run a query and then disconnects immediately after getting the result back and storing it in the dataset. This design of ADO.Net is called disconnected data architecture and is very much similar to the connectionless services of HTTP on the internet. ADO.Net also provides connection oriented traditional data access services.
An important aspect of disconnected architecture is that it maintains a local repository of data in the dataset object. The dataset object stores the tables, their relationship and their different constraints. The user can perform operations like update, insert and delete on this dataset locally, and the changes made to the dataset are applied to the actual database as a batch when needed. This greatly reduces network traffic and results in better performance.

Read More

Introduction to ADO .net

(Active Database Object)

ADO.NET is a set of classes that we can use with .NET framework and its supportable language to access data in a relational, table-oriented format. ADO.NET is an object oriented framework that allows you to interact with database systems.

Read More

C Language Introduction

C is a procedural programming language. It was initially developed by Dennis Ritchie in the year 1972. It was mainly developed as a system programming language to write an operating system. The main features of C language include low-level access to memory, a simple set of keywords, and clean style, these features make C language suitable for system programmings like an operating system or compiler development.

The structure of a C program is as follows:

C Language Program Structure
C Language Program Structure

The components of the above structure are:

  Header Files Inclusion: The first and foremost component is the inclusion of the Header files in a C program.
A header file is a file with extension .h which contains C function declarations and macro definitions to be shared between several source files.

Some of C Header files:

stddef.h – Defines several useful types and macros.
stdint.h – Defines exact width integer types.
stdio.h – Defines core input and output functions.
stdlib.h – Defines numeric conversion functions, pseudo random network generator, memory allocation.
string.h – Defines string handling functions.
math.h – Defines common mathematical functions.

Syntax to include a header file in C:

#include 

Main Method Declaratiometn: The next part of a C program is to declare the main() function. The syntax to declare the main function is:

Syntax to Declare main hod:

int main()
{}

Variable Declaration: The next part of any C program is the variable declaration. It refers to the variables that are to be used in the function. Please note that in the C program, no variable can be used without being declared. Also in a C program, the variables are to be declared before any operation in the function.

Example:

int main()
{
    int a;
.
.

Body: Body of a function in C program, refers to the operations that are performed in the functions. It can be anything like manipulations, searching, sorting, printing, etc.

Example:

int main()
{
    int a;

    printf("%d", a);
.
.

Return Statement: The last part in any C program is the return statement. The return statement refers to the returning of the values from a function. This return statement and return value depend upon the return type of the function. For example, if the return type is void, then there will be no return statement. In any other case, there will be a return statement and the return value will be of the type of the specified return type.

Read More

About C Language

C is a structured general purpose programming language. It was developed to rewrite the unix operating system. Earlier the unix operating system was written in B language. Almost the entire unix operating system and most of the programs run in it are written in C language.
The B language was written by Ken Thompson at Bell Laboratories in 1970. B was a type less language. That is, there was no concept of data types in B. B language did not gain much popularity.
C language was developed by Dennis Ritchie in 1972 at bell laboratories. C is a type full language. C language provides many data types.
C was a very short and simple language. Therefore, in a short time it became very popular and other computer scientists started using it as well.
There is no decrease in the popularity of C language even today. C language is taught before learning any other programming language. Because all the programming languages ​​(C ++, Java, PHP, C # etc) came after C language, they have somehow adopted C’s syntax.

Features of C Language

The reason for the popularity of C language is its features. These features make C language unique and powerful.

Structured

C is a structured programming language. In C, a program is created as small modules, called functions. By doing this, the programs are easy to manage and debug and big problems can also be solved easily.

Small

C provides 32 reserved keywords. These keywords provide programmer control over the language. By understanding the use of these keywords, you can do programming in C language. C language is small because it can be learned easily in a short time. Also, it is also easy to use.

Middle level

C is a middle level language. C is able to create both high level (very close to software) and low level (very close to hardware) applications.

This feature of C language is an advantage for programmers who want to create applications of both low and high levels. This feature makes C language flexible.

Fast

C language is considered the fastest language after assembly language. It is also sometimes called low level language. C language is close to hardware. So it is faster than other programming languages. Processing of applications created in C language is fast.

Case sensitive

C is a case sensitive language. In case sensitive programming languages ​​the capital and small variants of a letter are treated differently. This makes it easier for programmers to create identifiers.

Extendable

C is an extendable programming language. You can add your own libraries to C programs and use them.

Read More