Linux is Best Operating System

Linux is good operating system as compare to windows because it is open source and secure.

Ubuntu is also Good

Ubuntu operating system is used on client machines mostly to access servers remotly or other works

Linux Most secure Operationg system

Friends Its true Linux is a secure because in this all data store in files not in .exe or .dll everything is possible to edit.

Linux is little diffecult to Use

Linux is little diffecult to use but if you use it daily then you love it as we love it .

We love and respect the Indian Army

Indain Soldires are die for our freedom I love and respect Indian Army

Showing posts with label C-Programming. Show all posts
Showing posts with label C-Programming. Show all posts

Thursday, 24 April 2014

How to Use Goto keyword and exit function in C

Hello Friends i m Deepak Saini. Today i m trying to explain how to use the Goto And Exit keyword in C.
                                                     JAI HIND
                                                  JAI BHARAT

Love To :- My Father,My Mother, Govind Singh , DeadManINDIA,Sumit Dagar .

SO Lets start :- 

Goto Keyword :-  We are using goto keyword to jump the program to a switch or function.In my case i explain switch .


Exit function :- We are using exit function for  terminate the execution of a program.We are passing vaule one in this case when we are go for terminate the program execution.

Lets take a example :-

#include<stdio.h>
#include<stdlib.h>
int main()
{
int a;
printf("Enter the No =");
scanf("%d",&a);

if ( a <= 10 )
goto D;

else
{
             
printf("Enter this no =%d",a);

exit (1);

}

D:
printf("I am Deepak Saini" );

return 0;
}

Output 
Enter the no = 5
I am Deepak saini

Or 
Enter the no = 11
Enter this no = 11

Thats all gone when u execute this program .

In this program all things are use same we are use If condition or Goto Or exit (1)

We are use if condition for check input if condition true then execute our Goto keyword and we jump on switch D if condition is not true the our program print the else condition.And print the enterd no in this program and we are using the exit(1) for terminate the program.

THanks for reading if any mistake the comment we try to correct that and give u feed back.


                                       JAI HIND 
                                     JAI BHARAT

Tuesday, 22 April 2014

How to Use Switch Statement in C

#Jai_Hind Friends I am DeepakSaini  i m here to explain something about switch statement of C .
Love to :- My Father,My Mother,Sumit Dagar ,DeadManINDIA,Govind Singh <3 <3

Steups:- 

Steup1:- First of all we are explain how to declare switch in a program.
              
                    {
                      int a = 1;

                     switch(a)
                   {
                      case 1:
                     do this ;
                     break;
                      

                        case 2:
                      do this ;
                       break;
                     
                       default:
                       do this;
                        break;

                    }

    This is the way of declare the switch statement .


How it works 
1 check the case 1st if 1st match then break the and print the do this in my case which i define in 1st casse 

2 Then check 2nd and then check all cases which we are declare in the switch and at last we are define the default if none case match then print that do this . I explain this in my little program.


Here is the program.

#include<stdio.h>
int main()
{
int a;
printf (" enter the no 1 or 2 = \n");
scanf("%d",&a);

switch(a)
{
case 1:
printf("I am Deepak Saini\n");
break;

case 2:

printf("I love my MOM and DAD more then GOD\n");

break;

default:
printf("Happy go Lucky\n");

}

return 0;
}


We are using break statement to break if our case is matched if we are not using this then our program give all cases do this on screen. so we are using the break statement.


Thats it :) 
                                                   Jai Hind 
                                                   Jai Bharat 
                                    Ram Ram Dosto 



Tuesday, 8 April 2014

Loops In C language

Hello Friend I am Deepak Saini Again and tut for C language Loops may be helpfull for Noobs.

Lets Start :-

Loop :- We are using loops for repeat the instruction according to our condition.When the condition is false then our loop is terminate and give output of Else condition if we give in our program.

How many type of loops uses in C language.

We are using three type of loops in C .
1 For Loop
2 While loop
3 Do-While Loop

The While Loop :- I m not giving here big example but i just give a little example her .

Ex:-  #include<stdio.h>
           int main()
{
    int a ;

a = 1;

while ( a >= 5 )
{
   
 You do is here what u want to do 

a = a + 1;
}


I this we are using a = 1  and when a >= 5 then our loop is break otherwise its repeat the do .


In All loops we are using same method we are first insert the value of one variable then we are compare the value to the our condition value the we are  add one in this vaule and check the value is equal to or grater the our condition value then do next setup and our loop terminate and going for else or stop the program and exit.

Thats it i understand i share here if any problem then give feedback :) we  try to improve it and fix it in this tut.


Thanks For reading and Respect India and Indians:) 

           Jai Hind Jai Hind Jai Hind Jai Hind Jai Hind
          Jai Bharat Jai Bharat Jai Bharat Jai Bharat


_/\__/\_ :) 

Thursday, 3 April 2014

How we declare Variables in C

Hello Friends I m here to share today how we declare variable use in C language.

 Lets Start :)
 We are using mostly 3 or for types of variables how much i know i try to explain in C . 
:) 

Types of variables 
1 Integer          ----------> 0 1 2 3 4 5 6 7 8 9 
2 Character     ----------> a -z or A-Z
3 Float            ---------->  1.0 ,1.11 or etc like this which are we use decimals 
4 Var Char    -----------> In this type of variables we are store the no and alphabets together


How we Declare all that types Variables In C language 

Integer :-
                 int a ,b,c;

Here a b or c are the integer variables 


Character :- char d,e,f;

Here are d e or f are the characters.

Float :- float g,h,i;

Here g h or i are the floats .

Varchar :-  VARCHAR  a ,b ,c ;

Here we are declare the a b or c is the varchar variables in c.


How to set length in C character or Varchar ?


Character length :-    char a[10];
In this we are enter the value of a is less then or equal to 10 if we are trying to store the more then ten words the we are not get success.

Varchar length:- VARCHAR a[20];

Same as character we are able to store the 20 character in this type of varchar variables

Thanks For reading if any mistake the plz comment and after ur feedback we are fix the problem.

                                                   JAI HIND 
                                                 JAI BHARAT 

Wednesday, 2 April 2014

Character Set In C language

Jai Hind Dosto I am Again here :)

In this tut we are discuss of character set uses in C language.Not Big topic but just for knowledge.
Lets Start.

:- In C we are using alphabet,digit or special symbol used to represent information.

Alphabets ------------> A to Z
                                  a to z (in small ) 

Digits ---------------> 0,1,2,3,4,5,6,7,8,9

Special Symbols  -------------> ~ ` ! @ # $ % ^ & *  ( ) _ - + = | \ { } [ ] : ; " ' < > , . ? / 

Constants ,Variables,KeyWord :)

Constants :- A constant is an entity that doesn't change.
Variable :- A variable is an entity that may change.
Keyword :- A keyword is a word that carries special meaning. 

Constants are divided in to two categories 
1 Primary Constants
2 Secondary Constant 

Primary Constants -----> Integer constant,Real Constant ,Character Constant 
Secondary Constant -------> Array , Pointer ,Structure ,Union ,Enum etc.

Thats It Today I understand that only so I post here may be helpful for new peoples whose start to learn C.

Jai Hind :) If any Mistake then tell me i improve our knowledge 

                                                   Jai Hind Jai Bharat :) 

Tuesday, 1 April 2014

What is C ?

Hello Friends I just started to learn C language So i share form starting :)
Jai Hind To all ;
What is C ?
C is a programming language developed at AT & T's Bell laboratories of USA in 1972.It was designed and written by a man named Dennis Ritchie.And after devlopment C replace the more familier language of that time like PL/I ALGOL etc.

Now C is replaced by C++,C#,Java.
Thats true friends now days C language is replaced by the C++ ,C# or Java.

Why we still need C language ?
C++,C# or Java make a use of a principle called object oriented programming(OOP) to organize the program. This organizing principle has lots of advantage to offer.But even while using this organizing principle you would still need a good hold over the language elements of C and the basic programming skills.Major parts of popular operating system like windows ,Unix ,Linux, are written in C.We are need device driver programs.these programs are exclusively written in C.We are also use C language to write the operating system for smartphone ,microwaves,Cameras.We are able to write these type electronic devices operating system in C language.We are also make 3d Games in C language we are using frameworks in that type game to run those .

How we are learn C language ?
There we are learn C language like English language.

Steups:-

How we learn English ?

Alphabets   ------------------> Words ----------------------->Sentences ------------------>Paragraph .

Same method We use to Learn C language.

Alphabets                                        Constants                          
Digits                   --------------------> Variables ---------------> Instructions ------------->Program
Special Symbols                              Keywords

Thanks For Read :)  Jai Hind to all 
if any mistake then plz tell me i try to fix it 

Tuesday, 18 March 2014

The top 10 ways to Make programming interesting and Effective


1. Developing Basics – A good understanding of the concepts is critical for attaining success. Without a strong base, one can never become a good programmer. It is the core concept that assist in designing and implementing the best solutions in the best possible manner. In case you feel, there is a gap you can always go back and review the basics.

2. Begin putting question tags (how, what) with each set of code written by you – You must have an enthusiasm for knowing what and how things are happening. Although at times there may be time restrictions that may not permit you to test your code and assume that it will work. It is never a bad idea to try out or research as much as you can to ensure that your code is performing well.

3. Learning more by helping others – You must participate in forums for advice not only when you are in a crisis but also in normal circumstances. You can learn more by doing this habitually than simply for getting your problems solved. You must also help others in your team in solving their problems. This will only make you a better programmer.

4. Writing simple, comprehendible but logical code – You must write logical and simple codes to avoid complexity. As per experience, simple but logical codes always perform better and lead to lesser issues and are more extendable.

5. Invest more time in analyzing the problem for fixing it – You must invest more time in understanding and analyzing the problem and creating solutions for it. Designing can be as simple as looking at the sky, it does not have to imply using modeling languages and tools.

6. Before others you must analyze and review your code – This may be slightly difficult but you can try to break your code before anyone else does. Over time, you will master the art of writing bug-free code. You must do a close and unbiased review of your code and take others view on your code.

7. Stop feeling dismayed by looking at changing technology world – Change is inevitable. Working with new tools APIs, frameworks and others means coming up every day makes the programming easier and quicker. This will go on in the technology world. The point worth noting here is that the core and basic technologies changes happen at a much lesser pace compared to frameworks, tools and APIs surrounding it.

8. Work-arounds don’t work for longer time – On several occasions, software programmers come up with work around solutions. With passage of time, these work around solutions at all times result in the code getting corrupted, leaving it to become less extendible and maintainable and a huge amount of time wastage at a later time.

9. Reading Documentation – A good habit of a good programmer is reading documentation that may range from, JSR, API documents, tutorials etc. This helps in making that important foundation based on which you can program in the best possible manner.

10. Learning from others code as well – You must read other codes and refer to it from time to time in your daily work. This not only satisfies your knowledge of the basics but also helps in gaining knowledge of the best ways to write good programs.