Language: C++

#include <iostream>
using namespace std;

int main(){
	for(string s = ??? ???; s != null ;){
		cin >> s;
		
		char char[] = s;
		int int[s.size];
		int x=0;

		for(int i=0;i<s.size;i++){
			int[i] = char[i] - ???0???;
		}

		for(int j=0;j<s.size;j++){
			x += int[j];
		}

		if(x != 0)	cout << x << endl;
	}

return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:24: error: expected primary-expression before '?' token
    5 |         for(string s = ??? ???; s != null ;){
      |                        ^
a.cc:5:25: error: expected primary-expression before '?' token
    5 |         for(string s = ??? ???; s != null ;){
      |                         ^
a.cc:5:26: error: expected primary-expression before '?' token
    5 |         for(string s = ??? ???; s != null ;){
      |                          ^
a.cc:5:28: error: expected primary-expression before '?' token
    5 |         for(string s = ??? ???; s != null ;){
      |                            ^
a.cc:5:29: error: expected primary-expression before '?' token
    5 |         for(string s = ??? ???; s != null ;){
      |                             ^
a.cc:5:30: error: expected primary-expression before '?' token
    5 |         for(string s = ??? ???; s != null ;){
      |                              ^
a.cc:5:31: error: expected primary-expression before ';' token
    5 |         for(string s = ??? ???; s != null ;){
      |                               ^
a.cc:5:31: error: expected ':' before ';' token
    5 |         for(string s = ??? ???; s != null ;){
      |                               ^
      |                               :
a.cc:5:31: error: expected primary-expression before ';' token
a.cc:5:31: error: expected ':' before ';' token
    5 |         for(string s = ??? ???; s != null ;){
      |                               ^
      |                               :
a.cc:5:31: error: expected primary-expression before ';' token
a.cc:5:31: error: expected ':' before ';' token
    5 |         for(string s = ??? ???; s != null ;){
      |                               ^
      |                               :
a.cc:5:31: error: expected primary-expression before ';' token
a.cc:5:31: error: expected ':' before ';' token
    5 |         for(string s = ??? ???; s != null ;){
      |                               ^
      |                               :
a.cc:5:31: error: expected primary-expression before ';' token
a.cc:5:31: error: expected ':' before ';' token
    5 |         for(string s = ??? ???; s != null ;){
      |                               ^
      |                               :
a.cc:5:31: error: expected primary-expression before ';' token
a.cc:5:31: error: expected ':' before ';' token
    5 |         for(string s = ??? ???; s != null ;){
      |                               ^
      |                               :
a.cc:5:31: error: expected primary-expression before ';' token
a.cc:5:38: error: 'null' was not declared in this scope
    5 |         for(string s = ??? ???; s != null ;){
      |                                      ^~~~
a.cc:8:17: error: two or more data types in declaration of 'structured binding'
    8 |                 char char[] = s;
      |                 ^~~~
a.cc:8:26: error: empty structured binding declaration
    8 |                 char char[] = s;
      |                          ^~
a.cc:9:26: error: expected ']' before '.' token
    9 |                 int int[s.size];
      |                          ^
      |                          ]
a.cc:9:17: error: two or more data types in declaration of 'structured binding'
    9 |                 int int[s.size];
      |                 ^~~
a.cc:9:25: error: redeclaration of 'auto s'
    9 |                 int int[s.size];
      |                         ^
a.cc:5:20: note: 'std::string s' previously declared here
    5 |         for(string s = ??? ???; s != null ;){
      |                    ^
a.cc:9:32: error: expected initializer before ';' token
    9 |                 int int[s.size];
      |                                ^
a.cc:12:31: error: use of 's' before deduction of 'auto'
   12 |                 for(int i=0;i<s.size;i++){
      |                               ^
a.cc:13:28: error: structured binding declaration cannot have type 'int'
   13 |                         int[i] = char[i] - ???0???;
      |                            ^~~
a.cc:13:28: note: type must be cv-qualified 'auto' or reference to cv-qualified 'auto'
a.cc:13:29: error: redeclaration of 'auto i'
   13 |                         int[i] = char[i] - ???0???;
      |                             ^
a.cc:12:25: note: 'int i' previously declared here
   12 |                 for(int i=0;i<s.size;i++){
      |                         ^
a.cc:13:34: error: expected primary-expression before 'char'
   13 |                         int[i] = char[i] - ???0???;
      |                                  ^~~~
a.cc:13:34: error: expected ';' before 'char'
a.cc:16:31: error: use of 's' before deduction of 'auto'
   16 |                 for(int j=0;j<s.size;j++){
      |                               ^
a.cc:17:30: error: expected primary-expression before 'int'
   17 |                         x += int[j];
      |                              ^~~