#river crossing problem

44 messages · Page 1 of 1 (latest)

limber solarBOT
#

When your question is answered use !solved to mark the question as resolved.

Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question run !howto ask.

dry lava
#

Which line?

next night
dry lava
#

Which line is that in your code?

next night
dry lava
#

Can you paste the full error

next night
dry lava
#

Is that the full error?

#

And is that the only error?

next night
#

yes

dry lava
#

Do you have the full compile log in text format somewhere?

#

Maybe a different tab or something

next night
tidal jacinth
#

you arent showing us everything

next night
tidal jacinth
#

you just have to add using namespace std::literals::string_literals;

#

cuz these literals arent really enabled by default

#

it should compile now

#

@next night does it work now

next night
tidal jacinth
#

uh

#

what do the errors say

#

check

#

what are you using as IDE or text editor @next night

next night
#

cl

tidal jacinth
next night
#

24/49/49/74

tidal jacinth
next night
tidal jacinth
#

if its not compiling successfully can you give us the full compiler output log pls

#

idk how i can help you if you dont tho cuz the code compiles perfectly fine on godbolt

next night
#

It's showing those now

#

an online compailer showing that "ERROR!
g++ /tmp/TfHXtGTHqu.cpp
/tmp/TfHXtGTHqu.cpp: In member function 'void NehirKarsiyaGecis::kaydir(const std::string&)':
/tmp/TfHXtGTHqu.cpp:50:14: error: 'cout' is not a member of 'std'
50 | std::cout << "Tekneyi 4 " << rol << " ile kaydiriyoruz.\n";
| ^~~~
/tmp/TfHXtGTHqu.cpp:5:1: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
4 | #include <condition_variable>
+++ |+#include <iostream>
5 | #include <string>
"

dry lava
#

seems like your stdlib is fucked

#

actually did you add the include like it suggested?

next night
#

I'm a beginner in c++

dry lava
#

do you have #include <iostream>?

next night
#

yes

tidal jacinth
#

are you sure you setup clion correctly?

next night
#

here are two results