Borderou de evaluare (job #3275761)

Utilizator Alex_BerbescuBerbescu Alexandru Alex_Berbescu Data 11 februarie 2025 18:32:19
Problema Blis Status done
Runda Arhiva de probleme Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp:1:58: warning: bad option '-f fast-math' to pragma 'optimize' [-Wpragmas] 1 | #pragma GCC optimize("O3, fast-math, Ofast, unroll-loops") | ^ main.cpp:1:58: warning: bad option '-f Ofast' to pragma 'optimize' [-Wpragmas] main.cpp:1:58: warning: bad option '-f unroll-loops' to pragma 'optimize' [-Wpragmas] main.cpp:21:31: warning: bad option '-f fast-math' to attribute 'optimize' [-Wattributes] 21 | int cb(int st, int dr, int val) | ^ main.cpp:21:31: warning: bad option '-f Ofast' to attribute 'optimize' [-Wattributes] main.cpp:21:31: warning: bad option '-f unroll-loops' to attribute 'optimize' [-Wattributes] main.cpp:46:37: warning: bad option '-f fast-math' to attribute 'optimize' [-Wattributes] 46 | int32_t main(int argc, char * argv[]) | ^ main.cpp:46:37: warning: bad option '-f Ofast' to attribute 'optimize' [-Wattributes] main.cpp:46:37: warning: bad option '-f unroll-loops' to attribute 'optimize' [-Wattributes] main.cpp: In function 'int32_t main(int, char**)': main.cpp:50:9: error: no match for 'operator>>' (operand types are 'std::ifstream' {aka 'std::basic_ifstream<char>'} and 'char*') 50 | fin >> (s + 1); | ~~~ ^~ ~~~~~~~ | | | | | char* | std::ifstream {aka std::basic_ifstream<char>} In file included from /usr/include/c++/12.2.1/sstream:38, from /usr/include/c++/12.2.1/complex:45, from /usr/include/c++/12.2.1/ccomplex:39, from /usr/include/c++/12.2.1/x86_64-pc-linux-gnu/bits/stdc++.h:54, from main.cpp:2: /usr/include/c++/12.2.1/istream:168:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(bool&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' (near match) 168 | operator>>(bool& __n) | ^~~~~~~~ /usr/include/c++/12.2.1/istream:168:7: note: conversion of argument 1 would be ill-formed: main.cpp:50:15: warning: comparing the result of pointer addition '(((char*)(& s)) + 1)' and NULL [-Waddress] 50 | fin >> (s + 1); | ~~~^~~~ main.cpp:50:15: error: cannot bind non-const lvalue reference of type 'bool&' to a value of type 'char*' /usr/include/c++/12.2.1/istream:172:7: note: candidate: 'std::basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::operator>>(short int&) [with _CharT = char; _Traits = std::char_traits<char>]' (near match) 172 | operator>>(short& __n); | ^~~~~~~~ /usr/include/c++/12.2.1/istream:172:7: note: conversion of argument 1 would be ill-formed: main.cpp:50:15: error: invalid conversion from 'char*' to 'short int' [-fpermissive] 50 | fin >> (s + 1); | ~~~^~~~ | | | char* main.cpp:50:15: error: cannot bind rvalue '(short int)(((char*)(& s)) + 1)' to 'short int&' /usr/include/c++/12.2.1/istream:175:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(short unsigned int&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' (near match) 175 | operator>>(unsigned short& __n) | ^~~~~~~~ /usr/include/c++/12.2.1/istream:175:7: note: conversion of argument 1 would be ill-formed: main.cpp:50:15: error: invalid conversion from 'char*' to 'short unsigned int' [-fpermissive] Non zero exit status: 1

Ceva nu functioneaza?