How to call a function in main()?

Jaehunt jaeyoep at gmail.com
Tue Jul 23 15:39:18 PDT 2013


On Tuesday, 23 July 2013 at 22:27:40 UTC, bearophile wrote:
> Jaehunt:
>
>> I am new to programming.
>
> D is a large language, it will take lot of work and time to 
> learn it.
>
>
>> my function is look like "T[] sort(T)(T[] A) {}".
>>
>> What is main() look like to use the function?
>
> Take a look at the RosettaCode site, it contains hundreds of 
> small D programs of many different kinds, including an answer 
> to your question:
>
> http://rosettacode.org/wiki/Insertion_sort#D
>
> Bye,
> bearophile

Thank you for your advice and links.

I mean when function has "T[]" in the front, how am I calling it?

Thanks



More information about the Digitalmars-d-learn mailing list