Function can not return string ?

 
//------------ colortest --------------------
int colortest()
   {
   string res="any string";

//

   return(res);
   }
//-------------------------------------------

The code above gives compile error:

'(' - incompatible types

Now whats wrong with this puppy ??

 

change function type int --> string

eg, string colortest() { ...;return(res);}

would save u much frustration if look https://book.mql4.com/basics/functions

have u read book yes???

;)

Reason: