kapiaba Posted January 11, 2016 Report Share Posted January 11, 2016 Como resolver isto no HARBOUR? Em xHarbour funciona normal. No HARBOUR da erro de Sintaxe. MEMVAR x FUNCTION MAIN() // ? 1 ^^ 2 x := Cube( 1 ) ? x RETURN NIL Function Cube( n ) Return n ^^ 2 Obg. abs. Ronaldbuch 1 Quote Link to comment Share on other sites More sharing options...
Ariston Santos Posted January 11, 2016 Report Share Posted January 11, 2016 Só criando o cálculo na munheca. Dica: http://www.wikihow.com/Calculate-Cube-Root-by-Hand Quote Link to comment Share on other sites More sharing options...
vagner Posted January 12, 2016 Report Share Posted January 12, 2016 Como resolver isto no HARBOUR? Em xHarbour funciona normal. No HARBOUR da erro de Sintaxe. MEMVAR x FUNCTION MAIN() // ? 1 ^^ 2 x := Cube( 1 ) ? x RETURN NIL Function Cube( n ) Return n ^^ 2 Obg. abs. Já tentou assim ? Function Cube(n) Local nX := n^^ 2 Return(nX) Quote Link to comment Share on other sites More sharing options...
kapiaba Posted January 12, 2016 Author Report Share Posted January 12, 2016 Assim compila para os dois. MEMVAR x FUNCTION MAIN() // ? 1 ^^ 2 x := Cube( 1 ) ? x RETURN NIL Function Cube( n ) Return n ^ 2 Quote Link to comment Share on other sites More sharing options...
emotta Posted January 12, 2016 Report Share Posted January 12, 2016 mas assim é exponencial... dois circunflexos (^^) é criptografia.... Assim compila para os dois. MEMVAR x FUNCTION MAIN() // ? 1 ^^ 2 x := Cube( 1 ) ? x RETURN NIL Function Cube( n ) Return n ^ 2 kapiaba and vagner 2 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.