Language: C++

#include <iostream>
#include <string>
#include <vector>

using namespace std;

vector<string> split(string s, char delim = ',');
void dataInput(vector<vector<string> > &data);
double calcBMI(double w, double h);
void showFat(vector<vector<string> > data);

int main() {
  vector<vector<string> > data;

  dataInput(data);

  return 0;
}

vector<string> split(string s, char delim) {
	size_t pos = 0;
	vector<string> ret;
	while ((pos = s.find(delim)) != string::npos) {
		ret.push_back(s.substr(0, pos));
		s.erase(0, pos + 1);
	};
	ret.push_back(s);
	return ret;
}

void dataInput(vector<vector<string> > &data) {
  int i = 0;
  string temp;
  while(!cin.eof()) {
    cin >> temp;
    data[i].push_back(split(temp));

    i++;
  }

}

double calcBMI(double w, double h) {
  double BMI = 0.0;

  BMI = w / (h * h);

  return BMI
}

void showFat(vector<vector<string> > data) {
  int cnt = 0;
  double w = 0.0;
  double h = 0.0;

  while(cnt < data.size()) {
    w = stod(data[cnt][1]);
    h = stod(data[cnt][2]);
    if(25.0 <= calcBMI(w,h) {
      cout << data[cnt][0] << "\n";
    }
  }
}


Compiler output:
a.cc: In function 'void dataInput(std::vector<std::vector<std::__cxx11::basic_string<char> > >&)':
a.cc:36:22: error: no matching function for call to 'std::vector<std::__cxx11::basic_string<char> >::push_back(std::vector<std::__cxx11::basic_string<char> >)'
   36 |     data[i].push_back(split(temp));
      |     ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~
In file included from /usr/include/c++/14/vector:66,
                 from a.cc:3:
/usr/include/c++/14/bits/stl_vector.h:1283:7: note: candidate: 'void std::vector<_Tp, _Alloc>::push_back(const value_type&) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; value_type = std::__cxx11::basic_string<char>]'
 1283 |       push_back(const value_type& __x)
      |       ^~~~~~~~~
/usr/include/c++/14/bits/stl_vector.h:1283:35: note:   no known conversion for argument 1 from 'std::vector<std::__cxx11::basic_string<char> >' to 'const std::vector<std::__cxx11::basic_string<char> >::value_type&' {aka 'const std::__cxx11::basic_string<char>&'}
 1283 |       push_back(const value_type& __x)
      |                 ~~~~~~~~~~~~~~~~~~^~~
/usr/include/c++/14/bits/stl_vector.h:1300:7: note: candidate: 'void std::vector<_Tp, _Alloc>::push_back(value_type&&) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; value_type = std::__cxx11::basic_string<char>]'
 1300 |       push_back(value_type&& __x)
      |       ^~~~~~~~~
/usr/include/c++/14/bits/stl_vector.h:1300:30: note:   no known conversion for argument 1 from 'std::vector<std::__cxx11::basic_string<char> >' to 'std::vector<std::__cxx11::basic_string<char> >::value_type&&' {aka 'std::__cxx11::basic_string<char>&&'}
 1300 |       push_back(value_type&& __x)
      |                 ~~~~~~~~~~~~~^~~
a.cc: In function 'double calcBMI(double, double)':
a.cc:48:13: error: expected ';' before '}' token
   48 |   return BMI
      |             ^
      |             ;
   49 | }
      | ~            
a.cc: In function 'void showFat(std::vector<std::vector<std::__cxx11::basic_string<char> > >)':
a.cc:59:28: error: expected ')' before '{' token
   59 |     if(25.0 <= calcBMI(w,h) {
      |       ~                    ^~
      |                            )
a.cc:62:3: error: expected primary-expression before '}' token
   62 |   }
      |   ^