Showing posts with label Development. Show all posts
Showing posts with label Development. Show all posts

Monday, September 12, 2016

List of Important Programs in C language

/*1. Program to calculate the factorial of a Number*/
#include<stdio.h>
int main()
{
int fact=1,i,Num;
printf("Enter the value of Num:");
scanf("%d",&Num);
for(i=2;i<=Num;i++)
    fact=fact*i;
     printf("\nFactorial of %d is %d",Num,fact);
return 1;  
}

/*Program to Check whether the number is prime or not*/
#include<stdio.h>
int main()
{
int flag=1,i,Num;
printf("Enter the value of Num:");
scanf("%d",&Num);
for(i=2;i<Num;i++)
{
  if ((Num%i)==0)
  {
   flag=0;
    }
}
     if(flag==1)
         printf("Prime Number");
    else
         printf("Not Prime Number");
return 1;  
}
/*Optimized Program to Check whether the number is prime or not*/
#include<stdio.h>
int main()
{
int flag=1,i,Num;
printf("Enter the value of Num:");
scanf("%d",&Num);
for(i=2;i<Num/2;i++)
{
  if ((Num%i)==0)
  {
   flag=0;
    }
}
     if(flag==1)
         printf("Prime Number");
    else
         printf("Not Prime Number");
return 1;  
}
/*Program to print the pattern

*
**
***
****
*****

*/
#include<stdio.h>
int main()
{
int i,j;
for(i=1;i<=5;i++)
{
for(j=1;j<=i;j++)
{
printf("*");
}
printf("\n");
}
return 1;  
}

/*Program to print the pattern

    *
   * *
  * * *
 * * * *
* * * * *

*/
#include<stdio.h>
int main()
{
int i,j,k;
for(i=1;i<=5;i++)
{
for(k=1;k<6-i;k++)
   printf(" ");
for(j=1;j<=i;j++)
{
printf("* ");
}
printf("\n");
}
return 1;  
}

/*Program to print the pattern

A
B B
C C C
D D D D
E E E E E

*/
#include<stdio.h>
int main()
{
int i,j,k;
for(i=65;i<=69;i++)
{
  for(j=65;j<=i;j++)
{
printf("%c ",i);
}
printf("\n");
}
return 1;  
}

/*Program to print the pattern

A
A B
A B C
A B C D
A B C D E

*/
#include<stdio.h>
int main()
{
int i,j,k;
for(i=65;i<=69;i++)
{
  for(j=65;j<=i;j++)
{
printf("%c ",j);
}
printf("\n");
}
return 1;  
}



Sunday, August 28, 2016

Logical Components of an Android Mobile Application Development

Logical Components of an Android Mobile Application Development

 When you want to create a dynamic application then you have to require some important logical components of an Android application. There are four logical component of the Android Mobile Application Development:
1. Activity: Activity is one of the key logical component of the Android Mobile Application Development. It is the basis of User Interface of the app and makes the foundation of User Interface. User Interface contains visual elements , layout elements , resources and many more things.
Programmed component of the Used Interface which is programmed using java is an Activity and event handling. For example : Music is playing in background and in front you are using the browser.

2. Service: Service is another key component of an Android application. It always runs in the background and does not have a user interface. But UI is associated with it to interact with the service. In the music player, user need the UI to shuffle the songs or select the songs but for listening it not required to be in front of the mobile. User may use another app while listening the songs.

3. Broadcast Receiver: While you are using the mobile, there may be lots of announcement in your mobile related to low battery, download complete, incoming call, incoming SMS, availability of WI-FI Spot are initialed by the system. Some announcements are initiated by the app itself to let the other app understand. For Example: After completion of the download and is available of used.

4. Content Provider:  The data or content of the mobile app and is accessible across apps is the important aspect of mobile app development. However , due to security, any app required permission to access other app data . These data sharing after taking permission is done by using content provider. For example: for call a person whose detail is already saved in the contacts app, then contact app work as a content provider for calling , email and message app.
 

Some Important conceptual output based questions of Arrays and Pointers in C lnaguage

Some Important conceptual output based questions of Arrays and Pointers in C language 

1. 
void main()
{
   int Blog[]={1,2,3};
   printf("%d %d %d",Blog[1],Blog[2],Blog[3]);
}

Output: 2 3 0

Explanation: Here Blog[0],Blog[1] and Blog[2] will be initialized with 1,2 and 3 respectively. and rest are initialized with 0.

2.
void main()
{
   int Blog[]={33,44};
   printf("%x",Blog);
 }

Output: Base address of Blog

Explanation: The array name always holds the base address of an array. If we print *Blog then output will be the first value.

3.void main()
{
  int Blog[4]={22,33,44,55},*ptr,T;
  ptr=Blog;
  T=++(*ptr);
  printf("%d %d",*ptr,T);
 }

Ans: 23 23

Exlanation: *ptr points to the first element of an array Blog. After ++(*ptr) , the value 
of first element is increased by 1 that is 23 and also updated to the array. Hence the output will be 23 23.

4.
void main()
{
  int Blog[4]={22,33,44,55},*ptr,T;
  ptr=Blog;
  T=*(ptr++);
  printf("%d %d",*ptr,T);
 }

Ans: 33 22

Explanation: *ptr points to the first element of an array Blog. After *(ptr++), the pointer ptr points to next element that is second element of array but due to post increment the variable T contains the first element of an array Blog.

Sunday, August 21, 2016

Tips for Technical Interview in IT industry

Tips for Technical Interview in IT industry

  1. Prepare for a short introduction including the technical project which are genuinely done by you.
  2. Go through the website of company and get the information about company. for example: the company work for which domain primarily etc.
  3. Ask to seniors if any already working in the company about the technologies used by the company.
  4. Prepare yourself for the fundamentals of programming and algorithms because programming is the backbone of IT company.
  5. Prepare yourself comfortable upto average level(Concepts of classes,functions,datatypes,looping,conditional statement) for any one programming languages or tool.
post your query related to technical interview.

Saturday, August 20, 2016

Android Mobile Application Development

Android Mobile Application development is very easy. Mobile Application Development can be done by any body who have a basic programming knowledge of Java, XML, HTML. The tools required to develop a Mobile Application are:
1. Eclipse or Android Studio
2. Android SDK
3. jdk 1.7 and above

In next post I will give you step by step procedure to develop first mobile application.