Problem | typo |
---|---|
User | duck |
Submission Time | 2023-11-10 16:10:16 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
typo.cpp: In function ‘int main()’:
typo.cpp:7:27: error: conversion from ‘__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type’ {aka ‘char’} to non-scalar type ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} requested
7 | string c = a[i];
| ^
typo.cpp:9:22: error: cannot convert ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type’ {aka ‘char’} in assignment
9 | a[i+1] = c;
| ^
| |
| std::string {aka std::__cxx11::basic_string<char>}