题解 | #牛牛的快递#
牛牛的快递
https://www.nowcoder.com/practice/41b42e7b3c3547e3acf8e90c41d98270
#include <stdio.h> int main() { float a; char b; int c; scanf("%f %c",&a,&b); if(a<=1) c=20; else {if(a-(int)a==0) c = 20 + ((int)a-1 ) * 1; else c = 20 + (int)a * 1; } if(b=='y') c+=5; printf("%d",c); return 0; }