payroll -...

Info iconThis preview shows pages 1–4. Sign up to view the full content.

View Full Document Right Arrow Icon
Sheet1 Page 1 PAYROLL # include <iostream> # include <string> using namespace std int main() { string name, rank double civilstat double empstat double days double rate double tax double total double gross double net cout<<"Name:" cin>> name cout<<" "<< endl cout<<"Employee Status:"<<endl cout<<" "<< "Regular = 1"<<endl cout<<" "<<"Casual = 2"<<endl cout<<" "<<"Probation= 3"<<endl cout<<"Enter Employee Satus:" cin>> empstat
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Sheet1 Page 2 cout<<" "<< endl cout<<"Civil Status:"<<endl cout<<" "<<"Single = 1"<<endl cout<<" "<<"Married = 2"<<endl cout<<"Enter Civil Satus:" cin>> civilstat cout<<" "<< endl cout<<"Days Worked:" cin>> days cout<<" "<< endl cout<<"Rate:" if (empstat == 1) cout<<"2000"<<endl else if (empstat == 2) cout<<"1000"<<endl else if (empstat == 3) cout<<"1500"<<endl cout<<" "<< endl cout<<"Tax:" cout<<"2000"<<endl else if ((empstat == 1) && (civilstat == 2))
Background image of page 2
Sheet1 Page 3 cout<<"1800"<<endl
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Background image of page 4
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: cout&lt;&lt;&quot;1500&quot;&lt;&lt;endl else if ((empstat == 2) &amp;&amp; (civilstat == 2)) cout&lt;&lt;&quot;1000&quot;&lt;&lt;endl else if ((empstat == 3) &amp;&amp; (civilstat == 1)) cout&lt;&lt;&quot;1700&quot;&lt;&lt;endl else if ((empstat == 3) &amp;&amp; (civilstat == 2)) cout&lt;&lt;&quot;1200&quot;&lt;&lt;endl cout&lt;&lt;&quot; &quot;&lt;&lt; endl cout&lt;&lt;&quot;Gross Income:&quot; if (empstat == 1) gross=2000*days else if (empstat == 2) gross=1000*days else if (empstat == 3) gross=1500*days cout&lt;&lt;gross&lt;&lt;endl cout&lt;&lt;&quot; &quot;&lt;&lt; endl cout&lt;&lt;&quot;Net Income:&quot; if ((empstat == 1) &amp;&amp; (civilstat == 1)) net=gross-2000 else if ((empstat == 1 ) &amp;&amp; (civilstat == 2)) Sheet1 Page 4 net=gross-1800 else if ((empstat == 2) &amp;&amp; (civilstat == 1)) net=gross-1500 else if ((empstat == 2) &amp;&amp; (civilstat == 2)) net=gross-1000 else if ((empstat == 3) &amp;&amp; (civilstat == 1)) net=gross-1700 else if ((empstat == 3) &amp;&amp; (civilstat == 2)) net=gross-1200 cout&lt;&lt;net&lt;&lt;endl return 0 }...
View Full Document

This note was uploaded on 07/27/2011 for the course COL 201 taught by Professor Magtibay during the Winter '10 term at De La Salle Lipa.

Page1 / 4

payroll -...

This preview shows document pages 1 - 4. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online