当前位置:首页 » 编程语言 » 缴税c语言

缴税c语言

发布时间: 2022-10-30 16:03:25

Ⅰ 求c语言解答 个人工资所得税的计算:超过基准1600元以上的要纳税,超出基准的部分按下面的标准分段纳税:

#include <stdio.h>

double CaculateTax(int income,int pos)
{
double tax = 0.0;
int temp = income - pos;
if (temp <= 0)
tax = 0.0;
else if (temp <= 500)
tax = temp * 0.05;
else if (temp <= 2000)
tax = 500 * 0.05 + (temp - 500) * 0.1;
else if (temp <= 5000)
tax = 500 * 0.05 + 1500 * 0.1 + (temp - 2000) * 0.15;
else if (temp <= 20000)
tax = 500 * 0.05 + 1500 * 0.1 + 3000 * 0.15 + (temp - 5000) * 0.20;

return tax;
}

void main()
{
int income = 0;
int pos = 1600;
double tax = 0.0;
do
{
printf("Plean input your income : ");
scanf("%d", &income);
}while(income<0 || income > 20000);
tax = CaculateTax(income, pos);
printf("%lf\n", tax);
}

Ⅱ 在c语言里,用if语句编写一个程序,题目如下

#include
main()
{
int
s;
float
gongzi;
do{
printf("请输入工资:
");
scanf("%d",&s);
fflush(stdin);
if(s
<
1000)
{
printf("您的税后工资为:
%d\n您无需缴税;\n",s);
}
else
if(s
>=
1000
&&
s
<
2000)
{
gongzi
=
(float)s
*
0.95;
printf("您缴税金额为:%f,",
(float)s
*
0.05);
printf("您的税后工资为:
%f\n",gongzi);
}
else
if(s
>=
2000
&&
s
<
3000)
{
gongzi
=
(float)s
*
0.92;
printf("您缴税金额为:%f,",
(float)s
*
0.08);
printf("您的税后工资为:
%f\n",gongzi);
}
else
if(s
>=
3000
&&
s
<
5000)
{
gongzi
=
(float)s
*
0.9;
printf("您缴税金额为:%f,",
(float)s
*
0.1);
printf("您的税后工资为:
%f\n",gongzi);
}
else
if(s
>=
5000)
{
gongzi
=
(float)s
*
0.85;
printf("您缴税金额为:%f,",
(float)s
*
0.15);
printf("您的税后工资为:
%f\n",gongzi);
}
}while(s);/*输入工资为0结束*/
}

Ⅲ C语言 求个人所得税:3500以下不缴税,3500-4500征收5%,4500-6500征收10%,6500以上征收15%。

恕直言,你这代码有点胡写!

  1. 把所有类似if("4500<=a<6500")这样的语句都改成if(4500<=a && a<6500)。

  2. 把所有类似else{if...这样的写法都改成else if(...){...,不然一个if下的else就太多了。

  3. 把scanf("%d",&a);改成scanf("%lf",&a);。

  4. 把printf("%d ",b);改成printf("%f ",b);。

Ⅳ 个人所得税的C语言编程

#include<stdio.h>
intmain()
{doublex,y,p1,p2;
while(1)
{scanf("%lf",&x);
if(x<=0)break;
x-=3500;
if(x<=1500){p1=0.03;p2=0;}
elseif(x<=4500){p1=0.1;p2=105;}
elseif(x<=9000){p1=0.2;p2=555;}
elseif(x<=35000){p1=0.25;p2=1005;}
elseif(x<=55000){p1=0.3;p2=2755;}
elseif(x<=80000){p1=0.35;p2=5055;}
else{p1=0.45;p2=13505;}
y=x*p1-p2;
printf("个人所得税=%.2lf ",y);
}
return0;
}

Ⅳ 编程解决征税问题。10000元以上征%5,5000-10000征%3,1000-5000征%2,1000以下不征税.

这个问题好没水平,又没说用什么语言,好吧反正我无聊,C语言的程序如下:
#include<stdio.h>
void main(void)
{
long int income,tax;
float taxrate=0.0;
printf("请输入收入额: ");
scanf("%d",&income);
if(income>=10000)
taxrate=0.05;
else if(income<10000&&income>=5000)
taxrate = 0.03;
else if(income<5000&&income>=1000)
taxrate = 0.02;
else if(income<1000)
taxrate = 0.0;
tax = income*taxrate;
printf("应缴税 %d 元人民币\n",tax);

}

Ⅵ 写一个程序,输入任何一个公民的月收入和五险一金,能够计算他应缴纳的个人所得税。用C语言

假定5险一金固定是1000元,起征点是3500,程序如下:

#include <stdio.h>
int main(int argc, char *argv[])
{
float money,temp,total,t;
printf("请输入工资收入:");
scanf("%f",&money);
t=money-3500-1000; // 全月收入总额-1000(五险一金)-3500(现阶段个税起征点)

if (t<1500)
temp=t*0.03;
else
if (t<4500)
temp=1500*0.03+(t-1500)*0.1;
else
if (t<9000)
temp=1500*0.03+3000*0.1+(t-4500)*0.2;
else
if (t<35000)
temp=1500*0.03+3000*0.1+4500*0.2+(t-9000)*0.25;
else if (t<55000)
temp=1500*0.03+3000*0.1+4500*0.2+26000*0.25+(t-35000)*0.3;
else if (t<80000)
temp=1500*0.03+3000*0.1+4500*0.2+26000*0.25+20000*0.3+(t-55000)*0.35;
else
temp=1500*0.03+3000*0.1+4500*0.2+26000*0.25+20000*0.3+25000*0.35+(t-80000)*0.45;

total=money-temp;
printf("该工资扣除%8.2f的税收后,实际工资为:%8.2f\n",temp,total);

return 0;
}

Ⅶ 用C语言程序编一个个人所得税的源程序,求高手解答

/*
算法设计参考: http://ke..com/view/118.htm
算法:{(总工资)-(三险一金)-(免征额)}X税率-速扣数=个人所得税
全月应纳税所得额 税率 速算扣除数(元)
全月应纳税额不超过1500元 3% 0
全月应纳税额超过1500元至4500元 10% 105
全月应纳税额超过4500元至9000元 20% 555
全月应纳税额超过9000元至35000元 25% 1005
全月应纳税额超过35000元至55000元 30% 2755
全月应纳税额超过55000元至80000元 35% 5505
全月应纳税额超过80000元 45% 13505
*/#include <stdio.h>int main()
{
float money;//总金额
float submoney;//不应缴税金额
float result;//税收
float realmoney;//应缴税金额

scanf("%f",&money);//输入金额
scanf("%f",&submoney);//输入不应缴税金额

realmoney = money - submoney - 0;

if(realmoney <= 0)
{
result = 0;
}
else if(realmoney <= 1500 )//全月应纳税额不超过1500元
{
result = realmoney*0.03;
}
else if(realmoney <= 4500 )//全月应纳税额不超过4500元
{
result = realmoney*0.1-105;
}
else if(realmoney <= 9000 )//全月应纳税额不超过9000元
{
result = realmoney*0.2-555;
}
else if(realmoney <= 35000 )//全月应纳税额不超过35000元
{
result = realmoney*0.25-1005;
}
else if(realmoney <= 55000 )//全月应纳税额不超过55000元
{
result = realmoney*0.3-2755;
}
else if(realmoney <= 80000 )//全月应纳税额不超过80000元
{
result = realmoney*0.35-5505;
}
else//全月应纳税额超过80000元
{
result = realmoney*0.4-13505;
}

printf("个人所得税为:%.2f\n",result);

return 0;
}

Ⅷ C语言个人所得税计算系统

这样看能不能符合你的要求,说实话,分好少!不行的话可以追问
include<stdio.h>
void main()
{
double insure1=0.18; //个人承担保险金
double insure2=0.29; //他人承担保险金
int charge=3500; //费用扣除额
int pay=0; //基本工资
int fast=0; //速算金额
double cass=0.0; //税率
double ratepaying=0.0; //应纳税所得额
int type; //是又个人承担的,还是他人代付
double sum=0.0;

printf("请输入你当月取得的工资收入:%d",pay);
scanf("%d",&pay);
printf("个人所得税是由谁承担?(0:自己,1:他人代付):% d",type)
scanf("%d",&type);

if(type==0)
{
ratepaying=pay-pay*insure-charge;

if(ratepaying<=1500)
{
cass=0.03;
fast=0;
}
else if(ratepaying>1500 && ratepaying<=4500)
{
cass=0.1;
fast=105;
}
else if(ratepaying<4500 && ratepaying<=9000)
{
cass=0.2;
fast=555;
}
else if(ratepaying>9000 && ratepaying<=35000)
{
cass=0.25;
fast=1005;
}
else if(ratepaying>35000 && ratepaying<=55000)
{
cass=0.3;
fast=2755;
}
else if(ratepaying>55000 && ratepaying<=80000)
{
cass=0.35;
fast=5505;
}
else
{
cass=0.45;
fast=13505;
}
sum=ratepaying*cass-fast;
printf("应纳个人所得税税额为:%.2lf",sum)
}
else
{
ratepaying=pay-pay*insure-charge;

if(ratepaying<=1455)
{
cass=0.03;
fast=0;
}
else if(ratepaying>1455 && ratepaying<=4155)
{
cass=0.1;
fast=105;
}
else if(ratepaying<4155 && ratepaying<=7755)
{
cass=0.2;
fast=555;
}
else if(ratepaying>7755 && ratepaying<=27255)
{
cass=0.25;
fast=1005;
}
else if(ratepaying>27255 && ratepaying<=41255)
{
cass=0.3;
fast=2755;
}
else if(ratepaying>41255 && ratepaying<=57505)
{
cass=0.35;
fast=5505;
}
else
{
cass=0.45;
fast=13505;
}
sum=ratepaying*cass-fast;
printf("应纳个人所得税税额为:%.2lf",sum)
}
}

热点内容
一般电脑配置哪个好 发布:2025-05-20 10:40:58 浏览:602
我的世界撸树服务器 发布:2025-05-20 10:33:37 浏览:739
ftp搭建win7 发布:2025-05-20 10:06:06 浏览:82
访问坚果 发布:2025-05-20 10:06:02 浏览:394
ftpxlight 发布:2025-05-20 10:05:22 浏览:111
java的实验报告 发布:2025-05-20 10:02:06 浏览:528
豪华配置高电动轿车有哪些 发布:2025-05-20 10:01:59 浏览:487
哪些电脑配置低 发布:2025-05-20 09:34:16 浏览:955
地板网站源码 发布:2025-05-20 09:27:23 浏览:346
安卓视频转换器怎么使用 发布:2025-05-20 09:20:52 浏览:544