We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8c20b14 commit e5d3f1dCopy full SHA for e5d3f1d
solutions/gold/cf-100886G.mdx
@@ -35,7 +35,7 @@ using namespace std;
35
36
/** @return the product of the given string's digits (-1 if empty) */
37
ll prod(string s) {
38
- if (!s.length()) return -1;
+ if (!s.length()) { return -1; }
39
ll res = 1;
40
for (char c : s) { res *= c - '0'; }
41
return res;
0 commit comments