Computer Science Project
Computer Science Project
PROJECT
SUBMITTED TO:
ASHUTOSH SIR
SUBMITTED BY:
AAKANCHA VERMA
SHREEJITA BISWAS
1
INDEX
Sr. No. Contents Page No.
1. Certificate 3
2. Acknowledgement 4
3. Introduction to Java 5
4. The Project 6-28
The Question 6
The Source Code 6-16
The Outputs 17-28
5. Conclusion 29
6. Bibliography 30
7. Thank You 31
2
CERTIFICATE
_______________________ ___________________
Signature of Computer Science teacher Signature of Principal
(Mr. Ashutosh Kumar)
3
ACKNOWLEDGEMENT
Firstly, we would like to express my special thanks
of gratitude to our Computer Science teacher, Ashutosh Sir as
well as our Principal ma’am for giving us such a golden
opportunity to do this wonderful project which included to
write the source code and its output of a Java program, which
also helped us to do a lot of research, try out new ways of
executing a program and many more new things. It really
gave a boost to my knowledge in Java about various
statements. We are really thankful to them.
4
INTRODUCTION
In 1991, the Sun Micro Systems (Broomfield, Colorado, USA)
developed a complete language as a part of research work to develop software for the
consumer electronics. It was developed as a full-fledged programming language. It
could accomplish all sorts of tasks and solve the problems like other programming
languages like BASIC, C++. It was platform independent and hence the task could be
made portable from one system to another.
5
PROJECT REQUIREMENT
Windows:
This will run a standard installation. Follow the instructions on screen. The installer
will install the executable bluej.exe. Execute this to run BlueJ.
When executing BlueJ you might get dialog from the firewall asking you whether you
want to block or unblock BlueJ; we recommend that you choose not to block BlueJ.
If you have more than one Java version installed, BlueJ will let you select your
preferred version the first time it is executed. This can be changed later by running the
"Select BlueJ VM" utility from the Start menu.
6
Macintosh:
Note: BlueJ 3.0+ requires Java 6. Updating to the latest Java version (via the Mac OS
Software Update feature) is recommended. BlueJ 3.0.9 and later also has a package
which bundles Java 7, and does not require Java to be installed separately.
Download and expand the install file (BlueJ-309.zip). Move the resulting folder to
your preferred location (for example Applications).
Check your distribution's instructions on how to install "deb" packages. In many cases
it will be as simple as double-clicking the downloaded file from within a file manager,
and then providing an administrator password to allow the installation to proceed.
Note the "deb" package requires one of the following packages to be installed:
Thanks to Joe Lewis for providing the initial version of the .deb package.
Unix:
7
Make sure you have a suitable JDK. The Oracle JDK is recommended as it is the most
tested. Currently the "gij" (GNU java interpreter) cannot be used.
... where "/path/to/jdk" should be replaced by the actual path to the JDK.
Note: if you have a suitable java binary in a directory listed in your PATH
environment variable, you may be able to omit the "/path/to/jdk" above. Be careful
that this does not run an incompatible java implementation (such as "gij") however!
You can check if a Java implementation is in your path by runng "java -version".
In the installer, select an installation directory and your JDK directory and install. By
default, the installer will install into a directory called "bluej" inside the directory from
which you launch it, and it will pick up the JDK location automatically (if it is run
correctly according to the instructions above).
In the directory where BlueJ was installed, you will find a file named bluej. This is the
launcher script. Execute this script to start BlueJ. For example:
Note: This installer can be executed on any system with Java installed (including
Windows and MacOS), but Windows/MacOS specific icons and configurations will
not be present.
8
THE PROJECT
QUESTION:
SOURCE CODE:
import java.util.*;
double I;
String fname=sc.nextLine();
String g=sc.nextLine();
String salutation=sc.nextLine();
fname=fname.trim();
9
fname=fname+' ';
double Tax;
double inc;
for(int i=0;i<l;i++)
if(fname.charAt(i)==' ')
s=i;
break;
float age=sc.nextFloat();
if(age<=60)
Tax= ob.less_than_60(name,0);
else if((age>60)&&(age<=80))
10
Tax=ob.from_60_to_80(name,0);
else
Tax= ob.above_80(name,0);
if(age<=60)
inc= ob.less_than_60(name,1);
else if((age>60)&&(age<=80))
inc=ob.from_60_to_80(name,1);
else
inc= ob.above_80(name,1);
System.out.println("Gender: "+g);
11
System.out.println("Income: "+inc);
if (ch==0)
System.out.println(n+", Please Enter the total income for the Financial Year
2019-2020");
double income=a.nextDouble();
I=income;
double tax,surcharge=0,cess;
if (income<=250000)
tax=0;
12
else if((income>250000)&&(income<=500000))
tax=((income-250000)*(0.05));
cess=tax*(0.04);
tax=tax+cess;
else if ((income>500000)&&(income<=1000000))
tax=((income-500000)*(0.2))+12500;
tax=(tax*(0.04))+tax;
else
tax=((income-1000000)*(0.3))+112500;
tax=(tax*(0.04))+tax;
if((income>=5000000)&&(income<10000000))
surcharge=(0.1)*tax;
else if((income>=10000000)&&(income<20000000))
13
{
surcharge=(0.15)*tax;
else if((income>=20000000)&&(income<50000000))
surcharge=(0.25)*tax;
else if (income>=50000000)
surcharge=(0.37)*tax;
tax=tax+surcharge;
return(tax);
else
return(I);
14
if (ch==0)
System.out.println(n+", Please Enter the total income for the Financial Year
2019-2020");
double income=a.nextDouble();
I=income;
double tax=0,surcharge=0;
if (income<=300000)
tax=0;
else if((income>300000)&&(income<=500000))
tax=(income-300000)*(0.05);
tax=(tax*(0.04))+tax;
else if ((income>500000)&&(income<=1000000))
tax=((income-500000)*(0.2))+10000;
tax=tax+((0.04)*tax);
15
else
tax=((income-1000000)*(0.3))+110000;
tax=tax+(tax*(0.04));
if((income>=5000000)&&(income<10000000))
surcharge=(0.1)*tax;
else if((income>=10000000)&&(income<20000000))
surcharge=(0.15)*tax;
else if((income>=20000000)&&(income<50000000))
surcharge=(0.25)*tax;
else
surcharge=(0.37)*tax;
16
tax=tax+surcharge;
return(tax);
else
return(I);
if(ch==0)
System.out.println(n+", Please Enter the total income for the Financial Year
2019-2020");
double income=a.nextDouble();
I=income;
double tax=0,surcharge=0;
if (income<=500000)
tax=0;
17
}
else if ((income>500000)&&(income<=1000000))
tax=(income-500000)*(0.2);
tax=tax+(tax*(0.04));
else
tax=100000+((income-1000000)*(0.3));
tax=tax+(tax*(0.04));
if((income>=5000000)&&(income<10000000))
surcharge=(0.1)*tax;
else if((income>=10000000)&&(income<20000000))
surcharge=(0.15)*tax;
else if((income>=20000000)&&(income<50000000))
18
surcharge=(0.25)*tax;
else
surcharge=(0.37)*tax;
tax=tax+surcharge;
return(tax);
else
return(I);
19
OUTPUT:
Input
Output
Input
Output
20
Input
Output
Input
Output
21
Input
Output
Input
Output
22
Input
Output
Input
Output
23
Input
Output
Input
Output
24
Input
Output
Input
Output
25
Input
Output
Input
Output
26
Input
Output
Input
Output
27
Input
Output
Input
Output
28
Input
Output
Input
Output
29
Input
Output
Input
Output
30
Input
Output
31
CONCLUSION
From this project we came to know about many things about Java
fundamentals and programming of Java in an organized manner. We also learnt about
the basics of Income Tax file managed by the Central Government. Moreover, we
have learnt how to present project in an online platform through softwares like BlueJ
and Microsoft Word. Beside all this, we came to know how to by gather information
from various sources and websites to make a proper source code for making the
Income Tax file program and display the outputs in the project by taking screenshots
of the suitable examples required. We are really grateful to our school’s subject
teacher to choose this topic as our project question which can be helpful for our future.
- AAKANCHA VERMA
- SHREEJITA BISWAS
32
BIBLIOGRAPHY
With the help of our friends and family, this project is completed and we
have taken help from the following:
An article on Economic Times which showed the different income tax slabs for
different age groups. The following website is about the same
https://economictimes.indiatimes.com/wealth/tax/latest-income-tax-
slabs/articleshow/62751981.cms
33
34