A Complete Overview of Android App Development Tutorial :
Last Updated on: 12th Jul 2025 01:46:52 AM
Android is a mobile operating system Based on the Linux kernel developed by Google and later the Open Handset Alliance (OHA).Allows writing managed code in the Java language.
Unveiling of the Android platform was announced on 5 November 2007 with the founding of OHA. firstly Android was developed by the Andy Rubin, Rich Miner, Nick Sears and Chris White in Palo Alto, California on October, 2003.
and then Android was purchased by the GOOGLE in AUGUST,2005 for 50 million $.
"Open Handset Alliance™, a group of 84 technology and mobile companies who have come together to accelerate innovation in mobile and offer consumers a richer, less expensive, and better mobile experience.“
Quoting from www.OpenHandsetAlliance.com page
Bassically It's a consortium of several companies who worked on innovations of android mobile operating system.they have developed Together and committed to commercially deploy handsets and services using the Android Platform.It was established on 5th November, 2007, led by Google.
code | Version |
---|---|
class and object
#include<iostream.h>
using namespace std;
const int size=5;
class student {
int roll_no;
int total=0;
int marks[size];
public:
void getdata ();
void tot_marks ();
} ;
void student :: getdata () {
cout<<"\nEnter roll no: ";
cin>>roll_no;
for(int i=0; i<size; i++) {
cout<<"Enter marks in subject"<<(i+1)<<": ";
cin>>marks[i] ;
}
void student :: tot_marks() //calculating total marks {
for(int i=0; i<size; i++)
total + = marks[i];
cout<<"\n\nTotal marks "<<total;
}
int main() {
student stu;
stu.getdata() ;
stu.tot_marks() ;
return 0;
}
single inharitance in cpp
#include<iostream>
using namespace std;
class student
{
// single inheritance
int roll;
char name[10];
double marks;
public:
void read();
void display();
};
void student::read()
{
cout<<"enter your roll = ";
cin>>roll;
cout<<"enter your name = ";
cin>>name;
cout<<"enter your marks = " ;
cin>>marks;
}
void student::display()
{
cout<<"
your name is "<<name<<"
your roll is = " <<roll<<"
your marks is "<<marks;
}
class stud: public student
{
double mob;
char address[20];
public:
void read1()
{
//read();
cout<<"enter mobile no";
cin>>mob;
cout<<"Enter your Address";
cin>>address;
}
void display1()
{
//display();
cout<<"
your mob is " <<mob;
cout<<"
and address is "<<address;
}
} ;
int main ()
{
stud s;
s.read();
s.read1();
system("cls");
cout<<"____________________";
s.display();
s.display1();
return 0;
}
Multilevel
#include<iostream>
using namespace std;
class University{
string universityName;
public:
University(string uName):universityName(uName){
}
void displayUniversityDetails() {
cout << "University: " << universityName << endl;
}
};
class Collage: public University
{ public:
string collage_name;
Collage(string uName, string cName) : University(uName), collage_name(cName) {}
void displayCollegeDetails() {
displayUniversityDetails();
cout << "College: " << collage_name << endl;
}
};
class Department : public Collage {
public:
string departmentName;
Department(string uName, string cName, string dName)
: Collage(uName, cName), departmentName(dName) {}
void displayDepartmentDetails() {
displayCollegeDetails();
cout << "Department: " << departmentName << endl;
}
};
int main()
{
Department d("TNB","SSB","BCA");
d.displayDepartmentDetails();
return 0;
}
Multilevel
#include<iostream>
using namespace std;
class University{
string universityName;
public:
University(string uName):universityName(uName){
}
void displayUniversityDetails() {
cout << "University: " << universityName << endl;
}
};
class Collage: public University
{ public:
string collage_name;
Collage(string uName, string cName) : University(uName), collage_name(cName) {}
void displayCollegeDetails() {
displayUniversityDetails();
cout << "College: " << collage_name << endl;
}
};
class Department : public Collage {
public:
string departmentName;
Department(string uName, string cName, string dName)
: Collage(uName, cName), departmentName(dName) {}
void displayDepartmentDetails() {
displayCollegeDetails();
cout << "Department: " << departmentName << endl;
}
};
int main()
{
Department d("TNB","SSB","BCA");
d.displayDepartmentDetails();
return 0;
}
Multiple Inharitance in cpp
#include <iostream>
using namespace std;
class Animal // multiple inharitance
{
public:
void eat()
{
cout<<"animal is eating\n";
}
};
class Bird{
public:
void fly()
{
cout<<"Bird is flying\n";
}
};
class Parrot : public Animal, public Bird
{
public:
void speak()
{
cout<<"Parrot is speaking..\n";
}
};
int main()
{
Parrot p ;
p.eat();
p.fly();
p.speak();
return 0;
}
hiracr
#include <iostream>
using namespace std;
class person
{
char name[100],gender[10];
int age; //hierarchical inharitance
public:
void getdata()
{
cout<<"Name: ";
fflush(stdin); /*clears input stream*/
gets(name);
cout<<"Age: ";
cin>>age;
cout<<"Gender: ";
cin>>gender;
}
void display()
{
cout<<"Name: "<<name<<endl;
cout<<"Age: "<<age<<endl;
cout<<"Gender: "<<gender<<endl;
}
};
class student: public person
{
char institute[100], level[20];
public:
void getdata()
{
person::getdata();
cout<<"Name of College/School: ";
fflush(stdin);
gets(institute);
cout<<"Level: ";
cin>>level;
}
void display()
{
person::display();
cout<<"Name of College/School: "<<institute<<endl;
cout<<"Level: "<<level<<endl;
}
};
class employee: public person
{
char company[100];
float salary;
public:
void getdata()
{
person::getdata();
cout<<"Name of Company: ";
fflush(stdin);
gets(company);
cout<<"Salary: Rs.";
cin>>salary;
}
void display()
{
person::display();
cout<<"Name of Company: "<<company<<endl;
cout<<"Salary: Rs."<<salary<<endl;
}
};
int main()
{
student s;
employee e;
cout<<"Student"<<endl;
cout<<"Enter data"<<endl;
s.getdata();
cout<<endl<<"Displaying data"<<endl;
s.display();
cout<<endl<<"Employee"<<endl;
cout<<"Enter data"<<endl;
e.getdata();
cout<<endl<<"Displaying data"<<endl;
e.display();
return 0;
}
encapsulation
#include <iostream>
using namespace std;
class Student
{ // encapsulation
private:
string name;
int account_number;
public:
Student(string nm, int ac)
{
name=nm;
account_number=ac;
}
string getName()
{
return name;
}
int getAccount()
{
return account_number;
}
};
int main()
{
Student s("aarti",5675) ;
cout<<"My Name is "<<s.getName()<<"Account Number is "<<s.getAccount();
return 0;
}
jdbc
import java.sql.*; // set path// : set path=C:Program FilesJavajdk-17.0.2in
class Database{ // run javac -cp mysql-connector-java-8.0.29.jar;. Database.java
public static void main(String args[]){
try{
Class.forName("com.mysql.cj.jdbc.Driver");
//Connection con=DriverManager.getConnection("jdbc:mysql://localhost:4306/mydata","root","sandip@123");//xamp port
Connection con=DriverManager.getConnection("jdbc:mysql://localhost:3306/sandip","root","sandip@1234"); //mysql port
Statement stmt=con.createStatement();
ResultSet rs=stmt.executeQuery("select * from register");
while(rs.next())
System.out.println(rs.getInt(1)+" "+rs.getString(2)+" "+rs.getString(3));
con.close();
}catch(Exception e){ System.out.println(e);}
}
}