criyle/codenet-compile-errors huggingface dataset:
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H, W;
  
  
  vector<char> vec(W);
  
  for(int i = 0;i< H; i++){
    for(int i = 0; i < W; i++){
      cin >> vec.at(i);
    }
  }
  cout<< "#" << "#"*W << "#" <<endl;
  
  for(int i = 0; i < H; i++){
      cout<< "#" << vec.at(i) << "#" <<endl;
  }
  cout<< "#" << "#"*W << "#" <<endl;



}


Compiler output:
a.cc: In function 'int main()':
a.cc:15:20: error: invalid operands of types 'const char [2]' and 'int' to binary 'operator*'
   15 |   cout<< "#" << "#"*W << "#" <<endl;
      |                 ~~~^~
      |                 |   |
      |                 |   int
      |                 const char [2]
a.cc:20:20: error: invalid operands of types 'const char [2]' and 'int' to binary 'operator*'
   20 |   cout<< "#" << "#"*W << "#" <<endl;
      |                 ~~~^~
      |                 |   |
      |                 |   int
      |                 const char [2]
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H, W;
  int X = 2;
  
  
  vector<char> vec(W);
  
  for(int i = 0;i< H; i++){
    for(int i = 0; i < W; i++){
      cin >> vec.at(i);
    }
  }
  cout<< "#"*(W+X) <<endl;
  
  for(int i = 0; i < H; i++){
      cout<< "#" << vec.at(i) << "#" <<endl;
  }
   cout<< "#"*(W+X) <<endl;



}


Compiler output:
a.cc: In function 'int main()':
a.cc:16:13: error: invalid operands of types 'const char [2]' and 'int' to binary 'operator*'
   16 |   cout<< "#"*(W+X) <<endl;
      |          ~~~^~~~~~
      |          |     |
      |          |     int
      |          const char [2]
a.cc:21:14: error: invalid operands of types 'const char [2]' and 'int' to binary 'operator*'
   21 |    cout<< "#"*(W+X) <<endl;
      |           ~~~^~~~~~
      |           |     |
      |           |     int
      |           const char [2]
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H, W;
  
  vector<char> vec(W);
  
  for(int i = 0;i< H; i++){
    for(int i = 0; i < W; i++){
      cin >> vec.at(i);
    }
  }
  cout<< "#"*(W+2) <<endl;
  
  for(int i = 0; i < H; i++){
      cout<< "#" << vec.at(i) << "#" <<endl;
  }
   cout<< "#"*(W+2) <<endl;



}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:13: error: invalid operands of types 'const char [2]' and 'int' to binary 'operator*'
   14 |   cout<< "#"*(W+2) <<endl;
      |          ~~~^~~~~~
      |          |     |
      |          |     int
      |          const char [2]
a.cc:19:14: error: invalid operands of types 'const char [2]' and 'int' to binary 'operator*'
   19 |    cout<< "#"*(W+2) <<endl;
      |           ~~~^~~~~~
      |           |     |
      |           |     int
      |           const char [2]
Language: C++

#include<string.h>

int main(void){
	int H, W, i;
	do{
		scanf("%d%d", &H, &W);
	}while(H < 0 || H > 100 || W < 0 || W > 100);

	char a[100][100];
	for(i = 0; i < H; i++){
		do{
			scanf("%s", a[i]);
		}while(strlen(a[i]) > W);
	}

	for(i = 1; i <= W + 2; i++)
		printf("*");
	printf("\n");

	for(i = 0; i < H; i++)
		printf("*%s*\n", a[i]);

	for(i = 1; i <= W + 2; i++)
		printf("*");
	printf("\n");

	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:17: error: 'scanf' was not declared in this scope
    6 |                 scanf("%d%d", &H, &W);
      |                 ^~~~~
a.cc:12:25: error: 'scanf' was not declared in this scope
   12 |                         scanf("%s", a[i]);
      |                         ^~~~~
a.cc:17:17: error: 'printf' was not declared in this scope
   17 |                 printf("*");
      |                 ^~~~~~
a.cc:2:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
    1 | #include<string.h>
  +++ |+#include <cstdio>
    2 | 
a.cc:18:9: error: 'printf' was not declared in this scope
   18 |         printf("\n");
      |         ^~~~~~
a.cc:18:9: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H,W;
  cin >> H >> W;
  vector<char> image(H*W);
  for(int i=0;i<H*W;i++){
    cin >> image.at(i);
  }
  for(int i=0;i<(W+2);i++){
  cout << "#";
  }
  cout << endl;
  for(int i=0;i<W*H;i++){
    if(i%W==0){
    cout <<"#";
    }
    cout << image.at(i);
    if((i+1)%W==0){
    cout <<"#" <<endl;
    }
  }
  
  for(int i=0;i<(W+2)i++){
      cout << "#"; 
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:25:22: error: expected ';' before 'i'
   25 |   for(int i=0;i<(W+2)i++){
      |                      ^
      |                      ;
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H,W;
  cin >> H >> W;
  vector(string) image(H*W);
  for(int i=0;i<H*W;i++){
    cin >> image.at(i);
  }
  for(int i=0;i<W;i++){
  cout << "#";
  }
  cout << endl;
  for(int i=0;i<H*W;i=i++){
    if((i+1)%W==1){
      cout << "#";
    }
    cout << image.at(i);
    if((i+1)%W==0){
      cout << "#" << endl;
    }
  }
    

}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:9: error: missing template arguments before '(' token
    7 |   vector(string) image(H*W);
      |         ^
a.cc:7:16: error: expected primary-expression before ')' token
    7 |   vector(string) image(H*W);
      |                ^
a.cc:9:12: error: 'image' was not declared in this scope
    9 |     cin >> image.at(i);
      |            ^~~~~
a.cc:19:13: error: 'image' was not declared in this scope
   19 |     cout << image.at(i);
      |             ^~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H,W;
  cin >> H >> W;
  vector(char) image(H*W);
  for(int i=0;i<H*W;i++){
    cin >> image.at(i);
  }
  for(int i=0;i<W i++){
  cout << "#";
  }
  cout << endl;
  for(int i=0;i<H*W;i=i++){
    if((i+1)%W==1){
      cout << "#";
    }
    cout << image.at(i);
    if((i+1)%W==0){
      cout << "#" << endl;
    }
  }
    

}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:9: error: missing template arguments before '(' token
    7 |   vector(char) image(H*W);
      |         ^
a.cc:7:10: error: expected primary-expression before 'char'
    7 |   vector(char) image(H*W);
      |          ^~~~
a.cc:9:12: error: 'image' was not declared in this scope
    9 |     cin >> image.at(i);
      |            ^~~~~
a.cc:11:18: error: expected ';' before 'i'
   11 |   for(int i=0;i<W i++){
      |                  ^~
      |                  ;
a.cc:19:13: error: 'image' was not declared in this scope
   19 |     cout << image.at(i);
      |             ^~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
    int H,W;
    cin >> H >> W;
    vector<vector<char>> a;
    for (int i = 0; i < H; i++)
    {
        for (int j = 0; j < W; j++)
        {
            cin >> a[i][j];
        }
        
    }
    vector<vector<char>> b);
    for (int i = 0; i < H+2; i++)
    {
        for (int j = 0; j < W+2; j++)
        {
            if (i==0||i==H+1)
            {
                b[i][j]='#';
            }
            else
            {
                if (j==0||j==W+1)
                {
                    b[i][j]='#';
                }
                else
                {
                    b[i][j]=a[i-1][j-1];
                }
                
            }
            
        }
        
    }
    for (int i = 0; i < H+2; i++)
    {
        for (int j = 0; j < W+2; j++)
        {

            
            cout<<b[i][j];
            if (j==W+1)
            {
                cout<<endl;
            }
            

        }
        
    }
    
    


}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:27: error: expected initializer before ')' token
   15 |     vector<vector<char>> b);
      |                           ^
a.cc:22:17: error: 'b' was not declared in this scope
   22 |                 b[i][j]='#';
      |                 ^
a.cc:28:21: error: 'b' was not declared in this scope
   28 |                     b[i][j]='#';
      |                     ^
a.cc:32:21: error: 'b' was not declared in this scope
   32 |                     b[i][j]=a[i-1][j-1];
      |                     ^
a.cc:46:19: error: 'b' was not declared in this scope
   46 |             cout<<b[i][j];
      |                   ^
Language: C++

#include <bits/.stdc++.h>
using namespace std;

int main(){
	int H , W;
  	cin >> H >> W;
  	string S;
  	vector <char> result(W+2 , '#');
  	cout << result << endl;
	for (int i = 0 ; i < H ; i ++){
      cin >> S;
      for (int j = 0 ; j < W ; j++{ 
          result.at(j+1) = S.at();
      }
      cout << result << endl;
    }
  	cout << result << endl;
}

Compiler output:
a.cc:1:10: fatal error: bits/.stdc++.h: No such file or directory
    1 | #include <bits/.stdc++.h>
      |          ^~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H, W;
  cin >> H >> W;
  
  string s;
    for (int i = 0; i < W + 2; i++) {
      s += '#';
    }
  
  vector<char> a(H);
    for (int i = 0; i < H; i++) {
      cin >> a.at(i);
    }
  
  cout << s <<endl;
  for (int i = 0; i < H; i++) {
    cout << '#' + a.at(i) + '#' << endl;
  }
  cout << s << endl;
  
 


Compiler output:
a.cc: In function 'int main()':
a.cc:22:21: error: expected '}' at end of input
   22 |   cout << s << endl;
      |                     ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H, W;
  cin >> H >> W;
  
  string s;
    for (int i = 0; i < W + 2; i++) {
      s += '#';
    }
  
  vector<char> a(H);
    for (int i = 0; i < H; i++) {
      cin >> a.at(i);
    }
  
  cout << s <<endl;
  for (int i = 0; i < H; i++) {
    cout << '#' + a.at(i) + '#' << endl;
  }
  cout << s endl;
  
  
  
  for (int i = 0; i < N; i++) {
    cin >> A.at(i);
    sum += A.at(i);
  }
  
  ave = sum / N;
  
  for (int i = 0; i < N; i++) {
    if (ave - A.at(i) >= 0) {
      cout << ave - A.at(i) << endl;
    }
    else {
      cout << A.at(i) - ave << endl;
    }
  }
  
}


Compiler output:
a.cc: In function 'int main()':
a.cc:22:12: error: expected ';' before 'endl'
   22 |   cout << s endl;
      |            ^~~~~
      |            ;
a.cc:26:23: error: 'N' was not declared in this scope
   26 |   for (int i = 0; i < N; i++) {
      |                       ^
a.cc:27:12: error: 'A' was not declared in this scope
   27 |     cin >> A.at(i);
      |            ^
a.cc:28:5: error: 'sum' was not declared in this scope
   28 |     sum += A.at(i);
      |     ^~~
a.cc:31:3: error: 'ave' was not declared in this scope
   31 |   ave = sum / N;
      |   ^~~
a.cc:31:9: error: 'sum' was not declared in this scope
   31 |   ave = sum / N;
      |         ^~~
a.cc:31:15: error: 'N' was not declared in this scope
   31 |   ave = sum / N;
      |               ^
a.cc:34:15: error: 'A' was not declared in this scope
   34 |     if (ave - A.at(i) >= 0) {
      |               ^
Language: C++

#include<bits.stdc++/h>
using namespace std;
int main(){
   int H,W;
   cin>>H>>W;
   for(int i=0; i<W+1; i++){
      cout<<"#";
   }
   cout<<"#"<<endl;
   vector<int> tate(H);
   vector<int> yoko(W);
   for(int i=0; i<H; i++){
      for(int j=0; j<W; j++){
         cin>>yoko.at(j);
      }
      cout<<"#";
      for(int j=0; j<W; j++){
         cout<<yoko.at(j);
      }
      cout<<"#"<<endl;
   }
   for(int i=0; i<W+1; i++){
      cout<<"#";
   }
   cout<<"#"<<endl;
   return 0;
}

Compiler output:
a.cc:1:9: fatal error: bits.stdc++/h: No such file or directory
    1 | #include<bits.stdc++/h>
      |         ^~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include<bits.stdc++.h>
using namespace std;
int main(){
   int H,W;
   cin>>H>>W;
   for(int i=0; i<W+1; i++){
      cout<<"#";
   }
   cout<<"#"<<endl;
   vector<int> tate(H);
   vector<int> yoko(W);
   for(int i=0; i<H; i++){
      for(int j=0; j<W; j++){
         cin>>yoko.at(j);
      }
      cout<<"#";
      for(int j=0; j<W; j++){
         cout<<yoko.at(j);
      }
      cout<<"#"<<endl;
   }
   for(int i=0; i<W+1; i++){
      cout<<"#";
   }
   cout<<"#"<<endl;
   return 0;
}

Compiler output:
a.cc:1:9: fatal error: bits.stdc++.h: No such file or directory
    1 | #include<bits.stdc++.h>
      |         ^~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H, W;
  cin >> H >> W;
  
  for(int i = 0; i <W+2; i++){
    cout << "#" ;}
  cout << endl;
  
  vector<string> A(H)
  for(int i = 0; i < H; i++){
    cin >> A.at(i);
    cout << "#" << A.at(i) << "#" << endl;}
  
  for(int i = 0; i <W+2; i++){
    cout << "#" ;}
  cout << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:13:3: error: expected ',' or ';' before 'for'
   13 |   for(int i = 0; i < H; i++){
      |   ^~~
a.cc:13:18: error: 'i' was not declared in this scope
   13 |   for(int i = 0; i < H; i++){
      |                  ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H, W;
  cin >> H >> W;
  
  for(i = 0; i <W+2; i++){
    cout << "#" ;}
  cout << endl;
  
  vector<string> A(H)
  for(i = 0; i < H; i++){
    cin >> A.at(i);
    cout << "#" << A.at(i) << "#" << endl;}
  
  for(i = 0; i <W+2; i++){
    cout << "#" ;}
  cout << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:7: error: 'i' was not declared in this scope
    8 |   for(i = 0; i <W+2; i++){
      |       ^
a.cc:13:3: error: expected ',' or ';' before 'for'
   13 |   for(i = 0; i < H; i++){
      |   ^~~
a.cc:13:14: error: 'i' was not declared in this scope
   13 |   for(i = 0; i < H; i++){
      |              ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
int main() {
 int H,W;
 cin >> H >> W;
 vector<string> vec1(W);
 rep(i,W+2){
 cout << "#";
 }
 cout << endl;
 
 rep(i,W){
 cin >> vec1.at(i);
 }
 cout << "#";
 rep(i,W){
 cout << vec1.at(i);
 }
 cout << "#" << endl;
 }
 
 rep(i,W+1){
 cout << "#";
 }
 cout << endl;
}

Compiler output:
a.cc:3:19: error: expected unqualified-id before 'for'
    3 | #define rep(i, n) for (int i = 0; i < (int)(n); i++)
      |                   ^~~
a.cc:23:2: note: in expansion of macro 'rep'
   23 |  rep(i,W+1){
      |  ^~~
a.cc:23:6: error: 'i' does not name a type
   23 |  rep(i,W+1){
      |      ^
a.cc:3:35: note: in definition of macro 'rep'
    3 | #define rep(i, n) for (int i = 0; i < (int)(n); i++)
      |                                   ^
a.cc:23:6: error: 'i' does not name a type
   23 |  rep(i,W+1){
      |      ^
a.cc:3:49: note: in definition of macro 'rep'
    3 | #define rep(i, n) for (int i = 0; i < (int)(n); i++)
      |                                                 ^
a.cc:26:2: error: 'cout' does not name a type
   26 |  cout << endl;
      |  ^~~~
a.cc:27:1: error: expected declaration before '}' token
   27 | }
      | ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
int main() {
 int H,W;
 cin >> H >> W;
 vecter<string> vec2(H);
 vector<string> vec1(W);
 rep(i,W){
 cout << "#";
 cout << endl;
 }
 rep(i,H){
 rep(i,W){
 cin >> vec1.at(i);
 }
 rep(i,W){
 cout << "#" << vec1.at(i) << "#" << endl;
 }
 }
 rep(i,W){
 cout << "#";
 cout << endl;
 }
}    

Compiler output:
a.cc: In function 'int main()':
a.cc:7:2: error: 'vecter' was not declared in this scope
    7 |  vecter<string> vec2(H);
      |  ^~~~~~
a.cc:7:15: error: expected primary-expression before '>' token
    7 |  vecter<string> vec2(H);
      |               ^
a.cc:7:17: error: 'vec2' was not declared in this scope
    7 |  vecter<string> vec2(H);
      |                 ^~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  int H,W;
  cin>>H>>W;
  for(int i=0;i<H+2;i++){
    if(i==0 || i==H+1){
      vector<string> vec(W+2,"#");
      for(int j=0;j<W+2;j++){
        cout<<vec.at(j);
      }
      cout<<endl;
    }
    else{
      cin>>str;
      cout<<"#"<<str<<"#"<<endl;
    }
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:16:12: error: 'str' was not declared in this scope; did you mean 'std'?
   16 |       cin>>str;
      |            ^~~
      |            std
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H, W;
  
  vector<str>vec(H);
  for(int i = 0; i < H; i++){
    cin >> vec.at(i);
    
    i++ ;
      
  }
  
  cout<< "#"*(W+2) <<endl;
  
  for(int i = 0; i < H; i++){
    cout<< "#" << vec.at(i) << "#" <<endl;
    i++;
  }
   cout<< "#"*(W+2) <<endl;
  
  
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:10: error: 'str' was not declared in this scope; did you mean 'std'?
    7 |   vector<str>vec(H);
      |          ^~~
      |          std
a.cc:7:13: error: template argument 1 is invalid
    7 |   vector<str>vec(H);
      |             ^
a.cc:7:13: error: template argument 2 is invalid
a.cc:9:16: error: request for member 'at' in 'vec', which is of non-class type 'int'
    9 |     cin >> vec.at(i);
      |                ^~
a.cc:15:13: error: invalid operands of types 'const char [2]' and 'int' to binary 'operator*'
   15 |   cout<< "#"*(W+2) <<endl;
      |          ~~~^~~~~~
      |          |     |
      |          |     int
      |          const char [2]
a.cc:18:23: error: request for member 'at' in 'vec', which is of non-class type 'int'
   18 |     cout<< "#" << vec.at(i) << "#" <<endl;
      |                       ^~
a.cc:21:14: error: invalid operands of types 'const char [2]' and 'int' to binary 'operator*'
   21 |    cout<< "#"*(W+2) <<endl;
      |           ~~~^~~~~~
      |           |     |
      |           |     int
      |           const char [2]
Language: C++

#include <iostream>
#include <fstream>
#include <vector>
#include <cstring>
#include <algorithm>
#include <iomanip>

#define DEBUG 0
#define REP(i, n) for (long long i = 0; i < (n); i++) 
typedef long long ll;
static const ll MOD = 1000000007;
static const ll INF = 1000000000000000000LL;
using namespace std;


int main(){

    int h,w;
    cin >> h >> w;
    vector <string> a(h);

    REP(i,h)
    {
        cin .>> a[i];
    }

    REP(i,h+2)
    {
        REP(j,w+2)
        {
            if(i == 0 || i == h+1 || j == 0 || j == w+1)
            {
                cout << "#";
            }
            else
            {
                cout << a[i-1][j-1];
            }
        }
        cout << endl;
    }


    return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:24:14: error: expected unqualified-id before '>>' token
   24 |         cin .>> a[i];
      |              ^~
Language: C++

#include <bits/stdc++.h>
using namespace std;

int man(){
  int H,W;
  vector<string> a(W);
  for(int i=0; i<H; i++){
  for(int j=0; j<W; j++){
    cin >> a.at(j);
    }
  }
  for(int i=0; i<W+2; i++){
    cout << "#" << endl;
  }
  for(int i=0; i<H; i++){
    for(int j=0; j<W; j++){
      cout << "#" << a.at(j) << "#" << endl;
    }
  }
  for(int i=0; i<W+2; i++){
    cout << "#" << endl;
  }
}

Compiler output:
a.cc: In function 'int man()':
a.cc:23:1: warning: no return statement in function returning non-void [-Wreturn-type]
   23 | }
      | ^
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
Language: C++

#include <bits/stdc++.h>
using namespace std;

int man(){
  int H,W;
  vector<int> a(W);
  for(int i=0; i<H; i++){
  for(int j=0; j<W; j++){
    cin >> a.at(j);
    }
  }
  for(int i=0; i<W; i++){
    cout << "#" << endl;
  }
  for(int i=0; i<H; i++){
    for(int j=0; j<W; j++){
      cout << "#" << a.at(j) << "#" << endl;
    }
  }
  for(int i=0; i<W; i++){
    cout << "#" << endl;
  }
}

Compiler output:
a.cc: In function 'int man()':
a.cc:23:1: warning: no return statement in function returning non-void [-Wreturn-type]
   23 | }
      | ^
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
Language: C++

#include <bits/stdc++.h>
using namespace std;

int man(){
  int H,W;
  vector<int> a(W);
  for(int i=0; i<N; i++){
  for(int j=0; j<W; j++){
    cin >> a.at(j);
    }
  }
  for(int i=0; i<W; i++){
    cout << "#" << endl;
  }
  for(int i=0; i<N; i++){
    for(int j=0; j<W; j++){
      cout << "#" << a.at(j) << "#" << endl;
    }
  }
  for(int i=0; i<W; i++){
    cout << "#" << endl;
  }
}

Compiler output:
a.cc: In function 'int man()':
a.cc:7:18: error: 'N' was not declared in this scope
    7 |   for(int i=0; i<N; i++){
      |                  ^
a.cc:15:18: error: 'N' was not declared in this scope
   15 |   for(int i=0; i<N; i++){
      |                  ^
a.cc:23:1: warning: no return statement in function returning non-void [-Wreturn-type]
   23 | }
      | ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H, W;
  cin >> H >> W;
　char a[100][100], b[102][102];
  
  for(int i=0; i<H; i++){
    cin >> a[i];
  }
  
  for(int i = 0; i < H +2 ; i++){
  	for( int j=0; j < W+2; j++){
    	b[i][j] = '#';
    }
  }
  
  for( int i = 0; i < H; i++){
    for( int j=0; j < W; j++){
    	b[i+1][j+1] = a[i][j];
    }
  }
  
  for (int i = 0; i<H+2; i++){
    for(int j=0; j<W+2; j++){
		cout << b[i][j] << endl;
    }
  }
}


Compiler output:
a.cc:7:1: error: extended character 　 is not valid in an identifier
    7 | 　char a[100][100], b[102][102];
      | ^
a.cc: In function 'int main()':
a.cc:7:1: error: '\U00003000char' was not declared in this scope
    7 | 　char a[100][100], b[102][102];
      | ^~~~~~
a.cc:10:12: error: 'a' was not declared in this scope
   10 |     cin >> a[i];
      |            ^
a.cc:15:9: error: 'b' was not declared in this scope
   15 |         b[i][j] = '#';
      |         ^
a.cc:21:9: error: 'b' was not declared in this scope
   21 |         b[i+1][j+1] = a[i][j];
      |         ^
a.cc:21:23: error: 'a' was not declared in this scope
   21 |         b[i+1][j+1] = a[i][j];
      |                       ^
a.cc:27:25: error: 'b' was not declared in this scope
   27 |                 cout << b[i][j] << endl;
      |                         ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H, W;
  cin >> H >> W;
　char a[100][100], b[102][102];
  
  for(int i=0; i<H; i++){
    cin >> a[i];
  }
  
  for(int i = 0; i < H +2 ; i++){
  	for( int j=0; j < W+2; j++){
    	b[i][j] = "#";
    }
  }
  
  for( int i = 0; i < H; i++){
    for( int j=0; j < W; j++){
    	b[i+1][j+1] = a[i][j];
    }
  }
  
  for (int i = 0; i<H+2; i++){
    for(int j=0; j<W+2; j++){
		cout << b[i][j] << endl;
    }
  }
}


Compiler output:
a.cc:7:1: error: extended character 　 is not valid in an identifier
    7 | 　char a[100][100], b[102][102];
      | ^
a.cc: In function 'int main()':
a.cc:7:1: error: '\U00003000char' was not declared in this scope
    7 | 　char a[100][100], b[102][102];
      | ^~~~~~
a.cc:10:12: error: 'a' was not declared in this scope
   10 |     cin >> a[i];
      |            ^
a.cc:15:9: error: 'b' was not declared in this scope
   15 |         b[i][j] = "#";
      |         ^
a.cc:21:9: error: 'b' was not declared in this scope
   21 |         b[i+1][j+1] = a[i][j];
      |         ^
a.cc:21:23: error: 'a' was not declared in this scope
   21 |         b[i+1][j+1] = a[i][j];
      |                       ^
a.cc:27:25: error: 'b' was not declared in this scope
   27 |                 cout << b[i][j] << endl;
      |                         ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){
int h,w;
  cin>>h,w;
  vector<string> vec(h+2);
  for(int i=0;i<w+2;i++){
    vec(0)+="#";
    vec(h+1)+="#";
  }
  for(int i=1;i<h+1;i++){
    cin>>vec(i);
    vec(i)="#"+vec(i)+"#";
  }
  for(int i=0;i<h+2;i++){
    cout<<vec(i)<<endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:8: error: no match for call to '(std::vector<std::__cxx11::basic_string<char> >) (int)'
    9 |     vec(0)+="#";
      |     ~~~^~~
a.cc:10:8: error: no match for call to '(std::vector<std::__cxx11::basic_string<char> >) (int)'
   10 |     vec(h+1)+="#";
      |     ~~~^~~~~
a.cc:13:13: error: no match for call to '(std::vector<std::__cxx11::basic_string<char> >) (int&)'
   13 |     cin>>vec(i);
      |          ~~~^~~
a.cc:14:8: error: no match for call to '(std::vector<std::__cxx11::basic_string<char> >) (int&)'
   14 |     vec(i)="#"+vec(i)+"#";
      |     ~~~^~~
a.cc:14:19: error: no match for call to '(std::vector<std::__cxx11::basic_string<char> >) (int&)'
   14 |     vec(i)="#"+vec(i)+"#";
      |                ~~~^~~
a.cc:17:14: error: no match for call to '(std::vector<std::__cxx11::basic_string<char> >) (int&)'
   17 |     cout<<vec(i)<<endl;
      |           ~~~^~~
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){

    int h,w;

    cout << "h,wを入力 -> ";
    while(1){
        cin >> h >> w;
        cout <<"(h,w)=(" << h <<"," <<w<<")" << endl;
        
        if(h>=1 && h<=100 && w>=1 && w<=100){
            break;
        }
        else{
            cout << "1<= H,W <= 100. re-input." << endl;
        }
    }
    vector<vector<string>> pic(h, vector<string>(w));

     for(int i = 0; i< h; i++){
        cout << i <<"行目の英小文字を入力してください." << endl;
        for(int j = 0; j<w;j++){
            cin >> pic[i][j];
        }
        cout << endl;
    }
  return 0
}

Compiler output:
a.cc: In function 'int main()':
a.cc:29:11: error: expected ';' before '}' token
   29 |   return 0
      |           ^
      |           ;
   30 | }
      | ~
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){

    int h,w;

    cout << "h,wを入力 -> ";
    while(1){
        cin >> h >> w;
        cout <<"(h,w)=(" << h <<"," <<w<<")" << endl;
        
        if(h>=1 && h<=100 && w>=1 && w<=100){
            break;
        }
        else{
            cout << "1<= H,W <= 100. re-input." << endl;
        }
    }
    vector<vector<string>> pic(h, vector<string>(w));

     for(int i = 0; i< h; i++){
        cout << i <<"行目の英小文字を入力してください." << endl;
        for(int j = 0; j<w;j++){
            cin >> pic[i][j];
        }
        cout << endl;
       
     return 0;
     }

Compiler output:
a.cc: In function 'int main()':
a.cc:30:7: error: expected '}' at end of input
   30 |      }
      |       ^
a.cc:4:11: note: to match this '{'
    4 | int main(){
      |           ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){

    int h,w;

    cout << "h,wを入力 -> ";
    while(1){
    cin >> h >> w;
    cout <<"(h,w)=(" << h <<"," <<w<<")" << endl;
    
    if(h>=1 && h<=100 && w>=1 && w<=100)
        break;
    else{
        cout << "1<= H,W <= 100. re-input." << endl;
    }
    }
    vector<vector<string>> pic(h, vector<string>(w));
    //vector<string> pic(w*h);

    /*
    for(int i = 0; i< h; i++){
        cout << i <<"行目の英小文字を入力してください." << endl;
        for(int j = 0; j<w;j++){
            //cout <<"in!!!" << endl;
            cin >> pic[i][j]; 
       
        }
    }
    */

     for(int i = 0; i< h; i++){
        cout << i <<"行目の英小文字を入力してください." << endl;
        for(int j = 0; j<w;j++){
            cin >> pic[i][j];
        }
        cout << endl;
    }
/*
    cout <<"output1_original" << endl;
    for(int i = 0; i< h; i++){
        for(int j = 0; j<w;j++){
            if(j == 0)
                cout << endl;
            cout << pic[i][j]; 
       
        }
    }
    cout << endl;

  */  
    cout << "output2_with  " << endl;
    for(int row = -1; row<h+1; row++){
        for(int col = -1; col<w+1;col++){
            if(row==-1 || row== h || col == -1 || col == w){
                cout << "#";
            }
            else{
                cout << pic[row][col];
            }
        }
        cout << endl;
    }

Compiler output:
a.cc: In function 'int main()':
a.cc:64:6: error: expected '}' at end of input
   64 |     }
      |      ^
a.cc:4:11: note: to match this '{'
    4 | int main(){
      |           ^
Language: C++

#include <bits/stdc++.h>

using namespace std;

int main () {
  int H,W;
  string A
  
  
  

Compiler output:
a.cc: In function 'int main()':
a.cc:7:11: error: expected initializer at end of input
    7 |   string A
      |           ^
a.cc:7:11: error: expected '}' at end of input
a.cc:5:13: note: to match this '{'
    5 | int main () {
      |             ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int height, widgth;			//縦H, 横W
  cin >> height >> widgth;
  vector<string> lines(widgth);
  
  for(int line_i=0; line_i<height; line_i++)
    cin >> lines.at(line_i);
  
  for(int i=0; i<(widgth+2); i++)
    cout << "#" << endl;
  
  for(int i=0; i<height; i++)
    cout << "#" << lines(i) << "#" << endl;
  
  for(int i=0; i<(widgth+2); i++)
    cout << "#" << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:16:25: error: no match for call to '(std::vector<std::__cxx11::basic_string<char> >) (int&)'
   16 |     cout << "#" << lines(i) << "#" << endl;
      |                    ~~~~~^~~
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int height, widgth;			//縦H, 横W
  cin >> height >> widgth;
  vector<string> lines(widgth);
  
  for(int line_i=0; line_i<height; line_i++)
    cin >> lines.at(i);
  
  for(int i=0; i<(widgth+2); i++)
    cout << "#" << endl;
  
  for(int i=0; i<height; i++)
    cout << "#" << lines(i) << "#" << endl;
  
  for(int i=0; i<(widgth+2); i++)
    cout << "#" << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:21: error: 'i' was not declared in this scope
   10 |     cin >> lines.at(i);
      |                     ^
a.cc:16:25: error: no match for call to '(std::vector<std::__cxx11::basic_string<char> >) (int&)'
   16 |     cout << "#" << lines(i) << "#" << endl;
      |                    ~~~~~^~~
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int height, widgth;			//縦H, 横W
  cin >> height >> widgth;
  vector<string> lines(widgth);
  
  for(int line_i=0; line_i<height; line_i++)
    cin >> vec.at(i);
  
  for(int i=0; i<(widgth+2); i++)
    cout << "#" << endl;
  
  for(int i=0; i<height; i++)
    cout << "#" << lines(i) << "#" << endl;
  
  for(int i=0; i<(widgth+2); i++)
    cout << "#" << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:12: error: 'vec' was not declared in this scope
   10 |     cin >> vec.at(i);
      |            ^~~
a.cc:10:19: error: 'i' was not declared in this scope
   10 |     cin >> vec.at(i);
      |                   ^
a.cc:16:25: error: no match for call to '(std::vector<std::__cxx11::basic_string<char> >) (int&)'
   16 |     cout << "#" << lines(i) << "#" << endl;
      |                    ~~~~~^~~
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int height, widgth;			//縦H, 横W
  cin >> height >> widgth;
  vector<string> lines(widgth)
  
  for(int line_i=0; line_i<height; line_i++)
    cin >> vec.at(i);
  
  for(int i=0; i<(widgth+2); i++)
    cout << "#" << endl;
  
  for(int i=0; i<height; i++)
    cout << "#" << lines(i) << "#" << endl;
  
  for(int i=0; i<(widgth+2); i++)
    cout << "#" << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:3: error: expected ',' or ';' before 'for'
    9 |   for(int line_i=0; line_i<height; line_i++)
      |   ^~~
a.cc:9:21: error: 'line_i' was not declared in this scope; did you mean 'lines'?
    9 |   for(int line_i=0; line_i<height; line_i++)
      |                     ^~~~~~
      |                     lines
a.cc:16:25: error: no match for call to '(std::vector<std::__cxx11::basic_string<char> >) (int&)'
   16 |     cout << "#" << lines(i) << "#" << endl;
      |                    ~~~~~^~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main() {
    int H;
    1 <= H <= 100;
    int W;
    1 <= W <= 100;
    int a_ij;
    int a_HW
    cin >> H;
    cin >> W;
    cin >> a_HW;
    if ( W = 0 && 0 <= H <= (H + 1) ) {
        cout << '#';
    }
    if ( W = 0 && 1 <= H <= H ) {
        cout << '#';
    }
    if ( H = (W + 1) && 0 <= W <= (W + 1) ) {
        cout << '#';
    }
    if ( H = (H + 1) && 1 < W < W ) {
        cout << '#';
    }
   for(int i=1; i<=H; i++) {
        cout << a_ij;
    }
	for(int j=1; j<=W; j++) {
        cout << a_ij;
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:5: error: expected initializer before 'cin'
   10 |     cin >> H;
      |     ^~~
a.cc:12:12: error: 'a_HW' was not declared in this scope
   12 |     cin >> a_HW;
      |            ^~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main() {
    int H;
    1 <= H <= 100;
    int W;
    1 <= W <= 100;
    int a_ij;
    cin >> H;
    cin >> W;
    cin >> a_HW;
    if ( W = 0 && 0 <= H <= (H + 1) ) {
        cout << '#';
    }
    if ( W = 0 && 1 <= H <= H ) {
        cout << '#';
    }
    if ( H = (W + 1) && 0 <= W <= (W + 1) ) {
        cout << '#';
    }
    if ( H = (H + 1) && 1 < W < W ) {
        cout << '#';
    }
   for(int i=1; i<=H; i++) {
        cout << a_ij;
    }
	for(int j=1; j<=W; j++) {
        cout << a_ij;
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:12: error: 'a_HW' was not declared in this scope
   11 |     cin >> a_HW;
      |            ^~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main() {
    int H;
    1 <= H <= 100;
    int W;
    1 <= W <= 100;
    int a_HW;
    cin >> H;
    cin >> W;
    cin >> a_HW;
    if ( W = 0 && 0 <= H <= (H + 1) ) {
        cout << '#';
    }
    if ( W = 0 && 1 <= H <= H ) {
        cout << '#';
    }
    if ( H = (W + 1) && 0 <= W <= (W + 1) ) {
        cout << '#';
    }
    if ( H = (H + 1) && 1 < W < W ) {
        cout << '#';
    }
   for(int i=1; i<=H; i++) {
        cout << a_ij;
    }
	for(int j=1; j<=W; j++) {
        cout << a_ij;
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:25:17: error: 'a_ij' was not declared in this scope
   25 |         cout << a_ij;
      |                 ^~~~
a.cc:28:17: error: 'a_ij' was not declared in this scope
   28 |         cout << a_ij;
      |                 ^~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main() {
    int H;
    1 <= H <= 100;
    int W;
    1 <= W <= 100;
    int a_HW;
    cin >> H;
    cin >> W;
    cin >> a_HW;
    if ( W = 0 && 0 <= H <= (H + 1) ) {
        cout << '#';
    }
    if ( W = 0 && 1 <= H <= H ) {
        cout << '#';
    }
    if ( H = (W + 1) && 0 <= W <= (W + 1) ) {
        cout << '#';
    }
    if ( H = (H + 1) && 1 < W < W ) {
        cout << '#';
    }
   for(int i=1; i<=H; i++) {
        cout << a_ij;
    }
	for(j=1; j<=W; j++) {
        cout << a_ij;
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:25:17: error: 'a_ij' was not declared in this scope
   25 |         cout << a_ij;
      |                 ^~~~
a.cc:27:13: error: 'j' was not declared in this scope
   27 |         for(j=1; j<=W; j++) {
      |             ^
a.cc:28:17: error: 'a_ij' was not declared in this scope
   28 |         cout << a_ij;
      |                 ^~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main() {
    int H;
    1 <= H <= 100;
    int W;
    1 <= W <= 100;
    int a_HW;
    cin >> H;
    cin >> W;
    cin >> a_HW;
    for(H=1; W=1; H<=H); W<=W; H++; W++;) {
        cout << a_HW;
    }
    if ( W = 0 && 0 <= H <= (H + 1) ) {
        cout << '#';
    }
    if ( W = 0 && 1 <= H <= H ) {
        cout << '#';
    }
    if ( H = (W + 1) && 0 <= W <= (W + 1) ) {
        cout << '#';
    }
    if ( H = (H + 1) && 1 < W < W ) {
        cout << '#';
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:41: error: expected primary-expression before ')' token
   12 |     for(H=1; W=1; H<=H); W<=W; H++; W++;) {
      |                                         ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main() {
    int H;
    1 <= H <= 100;
    int W;
    1 <= W <= 100;
    int a_HW;
    cin >> H;
    cin >> W;
    cin >> a_HW;
    for(H=1; W=1; H<=H; W<=W; H++; W++) {
        cout << a_HW;
    }
    if ( W = 0 && 0 <= H <= (H + 1) ) {
        cout << '#';
    }
    if ( W = 0 && 1 <= H <= H ) {
        cout << '#';
    }
    if ( H = (W + 1) && 0 <= W <= (W + 1) ) {
        cout << '#';
    }
    if ( H = (H + 1) && 1 < W < W ) {
        cout << '#';
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:23: error: expected ')' before ';' token
   12 |     for(H=1; W=1; H<=H; W<=W; H++; W++) {
      |        ~              ^
      |                       )
a.cc:12:39: error: expected ';' before ')' token
   12 |     for(H=1; W=1; H<=H; W<=W; H++; W++) {
      |                                       ^
      |                                       ;
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main() {
    int H;
    1 <= H <= 100;
    int W;
    1 <= W <= 100;
    int a_HW;
    cin >> H;
    cin >> W;
    cin >> a_HW;
    for( H = 1; W = 1; (H <= H); (W <= W); H++; W++;) {
        cout << a_HW;
    }
    if ( W = 0 && 0 <= H <= (H + 1) ) {
        cout << '#';
    }
    if ( W = 0 && 1 <= H <= H ) {
        cout << '#';
    }
    if ( H = (W + 1) && 0 <= W <= (W + 1) ) {
        cout << '#';
    }
    if ( H = (H + 1) && 1 < W < W ) {
        cout << '#';
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:32: error: expected ')' before ';' token
   12 |     for( H = 1; W = 1; (H <= H); (W <= W); H++; W++;) {
      |        ~                       ^
      |                                )
a.cc:12:53: error: expected primary-expression before ')' token
   12 |     for( H = 1; W = 1; (H <= H); (W <= W); H++; W++;) {
      |                                                     ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main() {
    int H;
    1 <= H <= 100;
    int W;
    1 <= W <= 100;
    int a_HW;
    cin >> H;
    cin >> W;
    cin >> a_HW;
    for( H = 1; W = 1; H <= H; W <= W; H++; W++) {
        cout << a_HW;
    }
    if ( W = 0 && 0 <= H <= (H + 1) ) {
        cout << '#';
    }
    if ( W = 0 && 1 <= H <= H ) {
        cout << '#';
    }
    if ( H = (W + 1) && 0 <= W <= (W + 1) ) {
        cout << '#';
    }
    if ( H = (H + 1) && 1 < W < W ) {
        cout << '#';
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:30: error: expected ')' before ';' token
   12 |     for( H = 1; W = 1; H <= H; W <= W; H++; W++) {
      |        ~                     ^
      |                              )
a.cc:12:48: error: expected ';' before ')' token
   12 |     for( H = 1; W = 1; H <= H; W <= W; H++; W++) {
      |                                                ^
      |                                                ;
Language: C

#include <stdio.h>

int main(){
  int h, w;
  scanf("%d%d", &h, &w);
  char a[h][w];
  for(int i = 0; i < h; i++){
    for(int j = 0; j < w; j++){
        scanf("%c", &a[i][j]);
    }
  }
  for(i = 0; i < h+2; i++){
    printf("#");
  }
  printf("/n");
  for(i = 0; i < h; i++){
    printf("#");
    for(j = 0; j < w; j++){
      printf("%c", a[i][j]);
    }
    printf("#");
  }
  for(i = 0; i < h+2; i++){
    printf("#");
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:12:7: error: 'i' undeclared (first use in this function)
   12 |   for(i = 0; i < h+2; i++){
      |       ^
main.c:12:7: note: each undeclared identifier is reported only once for each function it appears in
main.c:18:9: error: 'j' undeclared (first use in this function)
   18 |     for(j = 0; j < w; j++){
      |         ^
Language: C

#include <stdio.h>

int main(void){
  int i,j,H=0,W=0;
  char a[H+2][W+2];
  scanf("%d",&H); scanf("%d¥n",&W);
  for(i=1; i<=H+1; i++){
    for(j=1; j<=W+1; j++){
      scnaf("%c",&a[i][j]);
    }
    printf("¥n");
  }
  for(i=0; i<=H+2; i++){
    for(j=0; j<=W+2; j++){
      if(i==0 || j==0 || i==H+2 || j== W+2){
        printf("#");
      }else{
        printf("%s",a[i][j]);
      }
    }
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:7: error: implicit declaration of function 'scnaf'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    9 |       scnaf("%c",&a[i][j]);
      |       ^~~~~
      |       scanf
Language: C

#include <stdio.h>

int main(void){
  int i,j,H=0,W=0;
  char a[H][W];
  scanf("%d",&H); scanf("%d¥n",&W);
  for(i=1; i<=H+1; i++){
    for(j=1; j<=W+1; j++){
      scnaf("%c",&a[i][j]);
    }
    printf("¥n");
  }
  for(i=0; i<=H+2; i++){
    for(j=0; j<=W+2; j++){
      if(i==0 || j==0 || i==H+2 || j== W+2){
        printf("#");
      }else{
        printf("%s",a[i][j]);
      }
    }
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:7: error: implicit declaration of function 'scnaf'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    9 |       scnaf("%c",&a[i][j]);
      |       ^~~~~
      |       scanf
Language: C

#include <stdio.h>

int main(void){
  int i,j,H,W;
  char a[][];
  scanf("%d",&H); scanf("%d¥n",&W);
  for(i=1; i<=H+1; i++){
    for(j=1; j<=W+1; j++){
      scnaf("%c",&a[i][j]);
    }
    printf("¥n");
  }
  for(i=0; i<=H+2; i++){
    for(j=0; j<=W+2; j++){
      if(i==0 || j==0 || i==H+2 || j== W+2){
        printf("#");
      }else{
        printf("%s",a[i][j]);
      }
    }
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:8: error: array type has incomplete element type 'char[]'
    5 |   char a[][];
      |        ^
main.c:5:8: note: declaration of 'a' as multidimensional array must have bounds for all dimensions except the first
main.c:9:7: error: implicit declaration of function 'scnaf'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    9 |       scnaf("%c",&a[i][j]);
      |       ^~~~~
      |       scanf
Language: C

#include <stdio.h>

int main(void){
  int i,j,H,W;
  string a[][];
  scanf("%d",&H); scanf("%d¥n",&W);
  for(i=1; i<=H+1; i++){
    for(j=1; j<=W+1; j++){
      scnaf("%c",&a[i][j]);
    }
    printf("¥n");
  }
  for(i=0; i<=H+2; i++){
    for(j=0; j<=W+2; j++){
      if(i==0 || j==0 || i==H+2 || j== W+2){
        printf("#");
      }else{
        printf("%s",a[i][j]);
      }
    }
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:3: error: unknown type name 'string'; did you mean 'stdin'?
    5 |   string a[][];
      |   ^~~~~~
      |   stdin
main.c:5:10: error: array type has incomplete element type 'int[]'
    5 |   string a[][];
      |          ^
main.c:5:10: note: declaration of 'a' as multidimensional array must have bounds for all dimensions except the first
main.c:9:7: error: implicit declaration of function 'scnaf'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    9 |       scnaf("%c",&a[i][j]);
      |       ^~~~~
      |       scanf
Language: C

#include <stdio.h>

int main(void){
  int i,j,H,W;
  string a[][];
  scanf("%d",&H); scanf("%d¥n",&W);
  for(i=1; i<=H+1; i++){
    for(j=1; j<=W+1; j++){
      scnaf("%s",&a[i][j]);
    }
    printf("¥n");
  }
  for(i=0; i<=H+2; i++){
    for(j=0; j<=W+2; j++){
      if(i==0 || j==0 || i==H+2 || j== W+2){
        printf("#");
      }else{
        printf("%s",a[i][j]);
      }
    }
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:3: error: unknown type name 'string'; did you mean 'stdin'?
    5 |   string a[][];
      |   ^~~~~~
      |   stdin
main.c:5:10: error: array type has incomplete element type 'int[]'
    5 |   string a[][];
      |          ^
main.c:5:10: note: declaration of 'a' as multidimensional array must have bounds for all dimensions except the first
main.c:9:7: error: implicit declaration of function 'scnaf'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    9 |       scnaf("%s",&a[i][j]);
      |       ^~~~~
      |       scanf
Language: C

#include <stdio.h>

int main(void){
  int a[][],i,j,H,W;
  scanf("%d",&H); scanf("%d¥n",&W);
  for(i=1; i<=H+1; i++){
    for(j=1; j<=W+1; j++){
      scnaf("%d",&a[i][j]);
    }
    printf("¥n");
  }
  for(i=0; i<=H+2; i++){
    for(j=0; j<=W+2; j++){
      if(i==0 || j==0 || i==H+2 || j== W+2){
        printf("#");
      }else{
        printf("%d",a[i][j]);
      }
    }
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:7: error: array type has incomplete element type 'int[]'
    4 |   int a[][],i,j,H,W;
      |       ^
main.c:4:7: note: declaration of 'a' as multidimensional array must have bounds for all dimensions except the first
main.c:8:7: error: implicit declaration of function 'scnaf'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    8 |       scnaf("%d",&a[i][j]);
      |       ^~~~~
      |       scanf
Language: C

#include <stdio.h>

int main(void){
  int i,j,H,W;
  scanf("%d",&H); scanf("%d¥n",&W);
  for(i=1; i<=H+1; i++){
    for(j=1; j<=W+1; j++){
      scnaf("%d",&a[i][j]);
    }
    printf("¥n");
  }
  for(i=0; i<=H+2; i++){
    for(j=0; j<=W+2; j++){
      if(i==0 || j==0 || i==H+2 || j== W+2){
        printf("#");
      }else{
        printf("%d",a[i][j]);
      }
    }
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:8:7: error: implicit declaration of function 'scnaf'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    8 |       scnaf("%d",&a[i][j]);
      |       ^~~~~
      |       scanf
main.c:8:19: error: 'a' undeclared (first use in this function)
    8 |       scnaf("%d",&a[i][j]);
      |                   ^
main.c:8:19: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

#include <iostream>
using namespace std;
int main() {
  int a, b, c, i;
  int A[999999999999999999999999999999999999999999999999] = {};
  cin >> a >> b >> c;
  for(i=0;i<a;i++) {
    cin >> A[i];
  }
  for(i=-2;i<b;i++) {
    cout << "#";
  }
  cout << endl;
  for(i=0;i<a;i++) {
    cout << "#" << A[i-1] << "#" << endl;
  }
   for(i=-2;i<b;i++) {
    cout << "#";
  }
  cout << endl;
  return 0;
}

Compiler output:
a.cc:5:9: warning: integer constant is too large for its type
    5 |   int A[999999999999999999999999999999999999999999999999] = {};
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
a.cc: In function 'int main()':
a.cc:5:7: error: size of array 'A' exceeds maximum object size '9223372036854775807'
    5 |   int A[999999999999999999999999999999999999999999999999] = {};
      |       ^
a.cc:8:12: error: 'A' was not declared in this scope
    8 |     cin >> A[i];
      |            ^
a.cc:15:20: error: 'A' was not declared in this scope
   15 |     cout << "#" << A[i-1] << "#" << endl;
      |                    ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){
  int H, W;
  cin >> H >> W;
  vector<string>low(H);
  for(int i=0; i<H; i++){
    cin >> low.at(i);
  }
  for(i=0; i<(W+2); i++){
    cout << '#';
  }
  cout << endl;
  for(int j=0; j<H; j++){
    /*for(i=0; i<(W+2); i++){
      if(i == 0 || i == (W+1)){
        cout << '#';
      }
    }*/
    cout << '#' << low.at(j) << '#';
  }
  cout << endl;
    for(i=0; i<(W+2); i++){
    cout << '#';
  }
  cout << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:7: error: 'i' was not declared in this scope
   11 |   for(i=0; i<(W+2); i++){
      |       ^
a.cc:24:9: error: 'i' was not declared in this scope
   24 |     for(i=0; i<(W+2); i++){
      |         ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H, W;
  cin >> H >> W;
  vector<string> str(H + 2);
  for(int i = 0; i < (H + 2); i++){
    if(i == 0 || i == H + 1){
      for(int j = 0; j < W; j++)
      str.at(i) += '#'
    }
    else
      cin >> str.at(i);
   cout << '#' << str.at(i) << '#' << endl; 
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:23: error: expected ';' before '}' token
   11 |       str.at(i) += '#'
      |                       ^
      |                       ;
   12 |     }
      |     ~
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int H, W;
  cin >> H >> W;
  vector<string> str(H + 2);
  for(int i = 0; i < (H + 2); i++){
    if(i == 0 || i == H + 1){
      for(int j = 0; j < W; j++)
      str += '#'
    }
    else
      cin >> str.at(i);
   cout << '#' << str.at(i) << '#' << endl; 
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:11: error: no match for 'operator+=' (operand types are 'std::vector<std::__cxx11::basic_string<char> >' and 'char')
   11 |       str += '#'
      |       ~~~~^~~~~~