Friday 11 July 2014

Program for Full Pyramid in C

Create Full Pyramid in C. Input can be taken by user.

#include<conio.h>
#include<stdio.h>
void main()
{
int n,i,j,k;
clrscr();
printf("Enter size");
scanf("%d",&n);

   for (i = 1; i <= n; i++)
   {
 for (j = 0; j < (n - i); j++)
printf("   ");
 for (j = 1; j <= i; j++)
printf(" * ");
 for (k = 1; k < i; k++)
printf(" * ");
 printf("\n");
   }

   for (i = n - 1;i >= 1; i--)
   {
 for (j = 0;j < (n - i); j++)
      printf("   ");
 for (j = 1;j <= i; j++)
printf(" * ");
 for (k = 1;k < i; k++)
      printf(" * ");
printf("\n");
   }

  printf("\n");
  getch();

    }

Program for Full Pyramid in Java

Program for Full Pyramid and size can be input by user.

import java.util.*;
public class Pyramid
{
    public static void main(String Args[])  
    {
        int n;
        Scanner sc = new Scanner(System.in);
               n= sc.nextInt();
   for (int i = 1; i <= n; i++)
            {
                  for (int j = 0; j < (n - i); j++)
                        System.out.print("   ");
                  for (int j = 1; j <= i; j++)
                        System.out.print(" * ");
                  for (int k = 1; k < i; k++)
                        System.out.print(" * ");
                  System.out.println();
            }

            for (int i = n - 1; i >= 1; i--)
            {
                  for (int j = 0; j < (n - i); j++)
                        System.out.print("   ");
                  for (int j = 1; j <= i; j++)
                        System.out.print(" * ");
                  for (int k = 1; k < i; k++)
                        System.out.print(" * ");
                  System.out.println();
            }

            System.out.println();
     
    }
 
}

Thursday 10 July 2014

Program for Right Triangle in Java

This is the program for Triangle and on place of "*" you can use any other variable as you want to print.

public class Triangle
{
    public static void main(String Args[])  
    {
    int i,j;
    for(i=0;i<10;i++)
 
    {
        System.out.println(" * ");
        for (j=0;j<=i;j++)
        {
            System.out.print(" * ");
       }}

    }
}

Wednesday 9 July 2014

Program to find Grade in C Language

#include<stdio.h>
#include<conio.h>
void main()
{
float per;
clrscr();
printf("enter your percentage");
scanf("%f",&per);
if(per>=60)
printf("\n1st division");
else if(per>=45)
printf("\n2nd division");
else if(per>=33)
printf("fail");
getch();
}

Program for Switch case with two cases

#include<stdio.h>
#include<conio.h>
void main()
{
int i;
clrscr();
i=2;
switch(i)
{
case 1:
{
printf("case 1");
}
case 2:
{
printf("case 2");
break;
}
default:
{
printf("default");
}
getch();
}
}

Program to print Hello in C

#include<stdio.h>
#include<conio.h>
void main()
{
clrscr();
printf("hello");
getch ();
}

Addition of two Numbers

#include<stdio.h>
#include<conio.h>
void main()
int a,b,c;
{
clrscr;
printf("\nenter the value of a");
printf("\nenter the value of b");
scanf("%d",a);
scanf("%d",b);
scanf("%d",c);
c=a+b;
getch();
}

Program for greatest of four numbers in java

Program is created using Switch-case and if else both. Switch case can be easily removed from this program.


import java.util.*;
public class Switchcase
{
    public static void main (String args[])
    {
        Scanner sc = new Scanner (System.in);
    System.out.println("please enter value of a");
    int a = sc.nextInt();
     System.out.println("please enter value of b");
    int b = sc.nextInt();
     System.out.println("please enter value of c");
    int c = sc.nextInt();
     System.out.println("please enter value of d");
    int d = sc.nextInt();
  int e=1;
  switch(1)
  {
      case 1:
          if (a>b&&a>c&&a>d)
          {
               
              System.out.println("Number a is greater than all");
          }
    else
     {
      if(b>a&&b>c&&b>d)
     {
          System.out.println("Number b is greater than all");
      }
       else
      {
      if(c>a&&c>b&&c>d)
      {
        System.out.println("Number c is greater than all");
      }
      else
      {
          if(d>a&&d>b&&d>c)
          {
              System.out.println("Number d is greater than all");
          }
            else
          {
                System.out.println("All numbers are equal");
      }
     }
    }
   }
  }
 }
}

Generations of computer.

Over the years, many computing devices were invented that are usrd by humans to solve different types of problems. All these computing devices can be classified into five generations which refer to the phase of improvement made to different computing devices results in a small,cheap,fast,reliable and productive computer. The technological development in the field od computer not only refers to the improvements made to the hardware technologies, but also improvement made to software twchnologies.
(i) First Generation (1940-1956) - The first generation of compuyer used the vacuum tubes technology for calculation as well as for storage control purposes. So, these computers are also called as vacuum tubes or thermionic valves based machines. A vacuum tube is a fragile glass device device, which use filament inside it. These vacuum tube computers could perform computation in milliseconds. The memory of these computers was constructed using electromagnetic relays, and all data and instructions were fed into the system from punced cards. These instructions were written in machine and assembly languages because high-level programming languages were introduced later. These first generation computers were mainly used for scientific computations. Some examples of these type of computers are-
ENIAC,
EDVAC,
EDSAC,
UNIVAC I,
IBM 710.
(ii) Second Generation (1956-1963) - A new electronic switching device, called transistor, was invented at Bell Laboratories in 1947 by John bardeen, Willam Shochley and Walter Brattain for which they won Noble Prize. A transistor is asemiconductor device that is used to increase the power of the incoming signals by preserving the shape of the original signal. It had three connections which are emitter (E), base(B), and collector(C). The base of transistor is the gate through the base through which the signal, needed to be amplified, is sent. The signal sent through the base terminal also acts as the input gate for the transistor. The collector of transistor is used to collect the amplified signal. The emitter of a transistor act as a output gate for emitting the amplified signal to the external environment. The second generation computers were manufactured using transistors in plqce of vacuum tubes to build the basic logic circuits.
The memory of these computers was composed of magnetic cores. Another major technological development made to these computers was thereplacement of the machine language with the assembly language. In second generation computers, an increasing usage of computer was seen in business and industry for commercial data processing applications like payrol, inventory control, marketing and producing planning. Some examples of second generation computers are-
PDP-8,
IBM1401,
IBM 7090.
Third Generation (1964-1975) - In 1958, Jach St. Clair Kilby and Robert Noyce inverted the first integrated circuit. The major Characteristics features of third generation computer systems was the use of Integrated circuits like transistors, resistors and capacitors grown on a single chip of silicon, eliminating wired interconnection between componets. The IC technology was also known as "microelectronics" tecnology because it made it possible to integrate large no. Of circuits components into very small surface of silicon , known as "chip". Initially ,the ICs contained only about ten to twenty componets. This technology was named small scale integration (SSI). So.e examples of third generation computers are-
NCR 395,
B6500,
IBM 370,
PDP 11,
CDC 7600.
(iv) Fourth Generation (1975-1989) - The average number of electronic components packed on a silicon chip doubled each year after 1965. This progress soon led to the era of large scale integration (LSI) when it was possible to integrate over 30000 electronic components in a single chip. As a result, the manufactures were able to reduce the size of the computers and made them cheaper as compared to the other generation of computers. The progress in  LSI and VLSI technologies led to the development of microprocessor. A microprocessor incorporates various components of a computer- such as CPU, memory and I/o control-onto a single chip. The intel P4004P mircoprocessor chip developed in 1971. Some popular later microprocessor include Intel 386, Intel 486, and pantium. The term personal computer (pc) became known to the people during this era.
During the fourth generation, magnatic core memories were replaced by semiconductor memories, resulting in larger random access memories with very fast access time. LANs became popular for connecting several dozen or even several hundred computers within an organization and WANs became popular for connection computer located at larger distances. This gave rise to network of computers and distributed system. Some examples of fourth generation computers are IBM PC, IBM PC/AT, Apple and CRAY-1.
(v) Fifth Generation (1989- present) - The different types of morden digital computers come under the catogaries of fifth generation computers. The fifth generation computers are based on ultra large scale integration (ULSI) technology rhat allows almost ten million electronic components to be fabricated one one small chip. The ULSI technology help in increasing the power and speed of miroprocessor chip and the capacity of primary and secondry to a great extent. As a result fifth generation computers are faster, cheaper and more efficient, as compared to fourt generation computers.

Sunday 6 July 2014

Advantages and disadvantages of Oral communication .

Oral communication has its advantages as well as disadvantages. Some of its advantages are-
(i) Oral words and speech have greater power than the written word. A powerful speaker can convince and sway people's opinions and arguments especially in an oral dialogue or group discussion.
(ii) It saves time. Oral communication is a face-to-face dialogue. which can be conducted anytime and anywhere and so it saves a lot of time. lt is especially useful when immediate action is required.
(iii) It saves money Written communication is costlier oral than communication especially when large groups within an organisation are involved.
(iv) It is easier to communicate orally especially, amongst large groups of people. Conferences, committees and meetings can be called and on communication with a large group can be easily carried on.
(v) Oral communication enables one to get immediate feedback and also respond accordingly The speaker receives an immediate response to one's communication and can thus answer the receivers queries and clarify his doubts.
(vi) oral communication by virtue ofbeing a dialogue is less formal than written communication. This can help in building personal relations and brings about openness between the speaker and receiver.
Oral communication has cerain disadvantages too. They are;
(i) Oral communication does not constitute written record and as such, have no legal validity.They cannot be referred to in cases ofdispute.
(ii) oral communication is highly unsuitable for lengthy and detailed messages.

Saturday 5 July 2014

Advantages and disadvantages of verbal communication.

The spoken word has a greater power than that of the written word. Oral communication is vital to human society be it the field ofeducation, the business sphere, or interpersonal relations. Whatever be the field, one's success is directly related to one's adeptness at oral communication.
Oral communication has its merits as well as demerits. Some ofthe merits are
(i) Oral words and speech have greater power the written than word. A powerful speaker can convince and sway people's opinions and arguments especially in an oal dialogue or group discussion. For a professional person adeptness at oral communication enables him to give convincing presentations, which goes a long way towards furthering his career.
(ii) It saves time. Oral communication is a face-to-face dialogue, which can be conducted anytime and anywhere. Large groups of people can be called together and addressed orally which saves a lot oftime.It is especially useful when immediate action is required.
(iii) It saves money. Written communication is costlier than oral communication especially when large groups within an organisation are involved.
(iv) It is easier to communicate orally especially amongst large groups of people. Conferences, committees and meetings can be called and oral communication with a large group can be easily carried on.
(v) Oral communication enables one   respond accordingly. The speaker receives an immediate response to one's communication and can thus answer the receivers queries and clarify his doubts. This enables matters to proceed further faster.
(vi) oral communication by virtue ofbeing a dialogue is less formal than written communication. There is personal interaction, which can help in building personal and bringing about openness between the speaker relations and receiver The listener give valuable in which can beneficial.
Oral communication has certain demerits too. They are
(i) oral communication does not constitute written record and as such, have no legal validity They cannot be referred to in cases of dispute.
(ii) oral communication is highly unsuitable for lengthy and detailed messages.
(iii) There is greater chance ofdistortion and misunderstanding with oral communication. One may have difficulty in recalling the exact message and may also misinterpret the message. This can lead to confusion and laxity in carrying out instructions.
(iv) In oral communication tone and modulation ofone's voice is as imporant as the actual words.Thus any feeling ofill will or sarcasm or resentment the par of either the speaker or the listener becomes immediately apparent in oral communication. This can make the situation awkward and difficult unlike, written communication where personal intenction is less imporant.
(v) oral communication can make it difficult to fix responsibility for mistakes and wrongdoing.

Monday 30 June 2014

What are the essentials of effective oral communication ?

The spoken word has a greater power than that of the written word. World leaders such as, Gandhi, Rousseau, Voltaire, Lincoln and Martin Luther King were adept at making speeches and rousing people's emotions. Their oral words exercised a tremendous influence on the common man and revolutions were brought about.
Oral communication is vital to human society be it the field of education, the business sphere, or interpersonal relations. A successful teacher is one who is able to clearly and effectively communicate his earning to his students. A well-run, successful organisation is one, which has a good and strong, formal and informal oral communication network between its management, workers and staff. The strength of our interpersonal relations also depends on our ability to have effective oral communication. Thus, whatever be the field, one's success is directly related to one's adeptness at oral communication. communication. Thus, whatever be the feld to one's success is directly related to one's adeptness at oral communication.