[julia-users] Re: switch case statement?
There is also a Switch package for Julia: https://github.com/dcjones/Switch.jl El domingo, 16 de diciembre de 2012, 5:00:17 (UTC-6), Erik Engheim escribió: > > I can not seem to find any type of *switch case* statement in Julia. What > is the alternative? I know I could always use *elseif *but that is > cumbersome. My thinking was that perhaps due to the type system one does > not need switch case as often. Usually we use swith case with enums, but I > guess in Julia one could use types, and just define a bunch of short > functions. But this is just speculation on my side I would have loved to > hear what the thinking is behind leaving out *switch-case* functionality.
Re: [julia-users] Re: switch case statement?
very interesting! El 18/01/2015 15:50, "Ismael VC" escribió: > There is also a Switch package for Julia: > https://github.com/dcjones/Switch.jl > > El domingo, 16 de diciembre de 2012, 5:00:17 (UTC-6), Erik Engheim > escribió: >> >> I can not seem to find any type of *switch case* statement in Julia. >> What is the alternative? I know I could always use *elseif *but that is >> cumbersome. My thinking was that perhaps due to the type system one does >> not need switch case as often. Usually we use swith case with enums, but I >> guess in Julia one could use types, and just define a bunch of short >> functions. But this is just speculation on my side I would have loved to >> hear what the thinking is behind leaving out *switch-case* functionality. > >