Advantages of LC as high level language--examples
Medard
liste.revo at medard.on-rev.com
Tue Nov 30 01:49:28 EST 2010
Devin Asay <devin_asay at byu.edu> wrote:
> In trying to explain to students how high level languages such as LiveCode
> can make development faster, I would like to give concrete examples of how
> single-line LC commands actually execute dozens of C++ commands in the
> engine. For example, a simple one-liner like:
>
> show field "demo" with visual effect dissolve
>
> Must have lots of lines of compiled C code behind it. Does anyone have any
> concrete examples? I may end up directing this to the mother ship, but
> thought I'd try here first.
I read something like this:
=====
During a round of recruiting at my last job at a tech startup in London
I got to experience first hand just how terrible most applicants are.
I interviewed a load of candidates who all claimed 5years + industry
experience so I was expecting great things. Unfortunately my incredibly
taxing interview question proved too much for them all ...
"In any language you like (with no attention paid to getting every last
semi-colon in the right place) write a function that reverses a string."
By the afternoon adding -
"Do not cheat and call your languages' equivalent of str_reverse."
No one managed it and I learned why I needed to phone screen people from
then on. :(
=====
I wondered myself whether it could simple with Revolution^W LiveCode
transcript^W xtalk*...
So I wrote a little demo stack to perform that task as an exercise
-- the readers of the french-speaking list already know that, by I think
it may respond to your request :-)
I proposed that to the list, and soon some co-lista answered with better
solutions!
The winner (IMHO) was a function including a loop with a for each
statement:
===
repeat for each char myChar in tWord
put myChar before tinvWord
end repeat
===
*not kidding: what is the name of the language in LC?
--
Medard
More information about the use-livecode
mailing list