【VC开源代码栏目提醒】:网学会员在VC开源代码频道为大家收集整理了MathFun.cpp提供大家参考,希望对大家有所帮助!
// MathFun.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
int MathFun(const int x)
{
if (x < 1)
return x;
else if (x < 30)
return 5*x - 1;
else
return 10*x - 5;
}
int main(int argc, char* argv[])
{
printf("%d\n",MathFun(20));
return 0;
}
上一篇:
Math.cpp
下一篇:
美术教学中网络信息论文