Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
155075 李一凡 12输出英文字母 C++ Compile Error 0 MS 0 KB 218 2026-05-31 14:01:13

Tests(0/0):


Code:

#include<bits/stdc++.h> using namespace std; int main() { for(char c="a";c<="z";c++){ cout<<c<<" "; } cout << endl; for(char c="Z";c<="A";c--){ cout<<c<<" "; } return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:5:13: error: invalid conversion from 'const char*' to 'char' [-fpermissive]
  for(char c="a";c<="z";c++){
             ^
Main.cc:5:20: warning: comparison with string literal results in unspecified behaviour [-Waddress]
  for(char c="a";c<="z";c++){
                    ^
Main.cc:5:20: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
Main.cc:9:13: error: invalid conversion from 'const char*' to 'char' [-fpermissive]
  for(char c="Z";c<="A";c--){
             ^
Main.cc:9:20: warning: comparison with string literal results in unspecified behaviour [-Waddress]
  for(char c="Z";c<="A";c--){
                    ^
Main.cc:9:20: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]