分段函数求值 c语言Description 已知:y是x的函数, 当x=-2,且x=3时,y=3x+4 Input 任意输入一个整数Output 输出其对应的函数值Sample Input -425 Sample Output 15-319求写程序.

来源:学生作业帮助网 编辑:作业帮 时间:2024/04/30 06:52:49
分段函数求值 c语言Description 已知:y是x的函数, 当x=-2,且x=3时,y=3x+4 Input 任意输入一个整数Output 输出其对应的函数值Sample Input -425 Sample Output 15-319求写程序.

分段函数求值 c语言Description 已知:y是x的函数, 当x=-2,且x=3时,y=3x+4 Input 任意输入一个整数Output 输出其对应的函数值Sample Input -425 Sample Output 15-319求写程序.
分段函数求值 c语言
Description 已知:y是x的函数,
当x=-2,且x=3时,y=3x+4
Input 任意输入一个整数
Output 输出其对应的函数值
Sample Input -4
2
5

Sample Output 15
-3
19
求写程序.

分段函数求值 c语言Description 已知:y是x的函数, 当x=-2,且x=3时,y=3x+4 Input 任意输入一个整数Output 输出其对应的函数值Sample Input -425 Sample Output 15-319求写程序.
# include
# include
void main()
{
int x;
int y;
while(1)
{
printf("input x:\n");
scanf("%d",&x);
if(x=-1 && x