弟弟的作业 (Java代码)——附带详细解析 摘要:解题思路:熟悉几个新的字符串方法的调用注意事项: * indexOf() 方法有以下四种形式: * public int indexOf(int ch): 返回指定字符在字符串中第一次出现处的索引,如…… 题解列表 2022年09月19日 0 点赞 0 评论 1224 浏览 评分:8.7
弟弟的作业 摘要:```c #include int main() { int a,b,c,k,count=0; char x; while(~(k=scanf("%d%c%d=%d…… 题解列表 2022年08月17日 0 点赞 0 评论 833 浏览 评分:9.9
c语言 弟弟的作业其实并不难,只要基础知识即可 摘要:解题思路:用结构体来接收内容,再用while(~scanf(……))来循环接收内容,最终我们判断等于号后面的是否是'?',如果是,就自动跳过(不用说肯定不是对的),如果不是我们来算一下…… 题解列表 2022年08月16日 0 点赞 0 评论 583 浏览 评分:0.0
编写题解 1073: 弟弟的作业 摘要:#include<iostream>using namespace std;int main(){ string st;int a=0,b=0,c=0;bool k=false,f=false;…… 题解列表 2022年07月31日 0 点赞 0 评论 558 浏览 评分:9.9
C# 1073: 弟弟的作业 atoi(s.c_str())函数 ```cpp#includeusingnamespacestd;intmain(){//列如1+2=3;inta,c,ans=0;//a和c储存1和2charb,d;//b和d储存+和=strings;//s用来储存3这个位置的,因为题目说可能为‘?’, 题解列表 2022年07月28日 0 点赞 0 评论 622 浏览 评分:0.0
1073: 弟弟的作业 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int main(){ int a,b,c; char x; in…… 题解列表 2022年05月02日 0 点赞 0 评论 460 浏览 评分:0.0
编写题解 1073: 弟弟的作业(python 简单易懂) 摘要:score = 0 while True: try: user = input().split("=") if user[1] == "?&quo 题解列表 2022年04月18日 0 点赞 0 评论 1125 浏览 评分:9.3
1073: 弟弟的作业 摘要:解题思路:(1)题目把输入的格式做了很严格的限制,所以直接按照 cin >> num1 >> op1 >> num2 >> op2 >> res 的格式读输入就行了。(2)res 是字符串,因为可能不…… 题解列表 2022年04月17日 0 点赞 0 评论 955 浏览 评分:9.9
弟弟的作业(C++代码) 摘要:解题思路:输入字符串,分别用while循环从字符串中把第一个数、第二个数和算式的结果放到整数a,b,c中,k是运算符号+或-;c的循环前要先判断"="后是否为"?",是问号的话直接判错;最后根据k的值…… 题解列表 2022年04月14日 0 点赞 0 评论 758 浏览 评分:0.0
[Sapphire]1073:弟弟的作业(思路简单)(C语言代码) 弟弟的作业Sapphire2022/2/23解题思路:建议直接看题解。你可能有的疑惑:1.为什么要chard[3]而不直接chard?答:因为当你输入99到d时,如果是chard,只能读取到9这个字符,所以我们只好放弃用d-'0'这样的思路。 题解列表 2022年02月23日 0 点赞 0 评论 851 浏览 评分:8.0