Talk:Range extraction: Difference between revisions

On Algol and duck typing.
(Do we do this elsewhere?)
(On Algol and duck typing.)
Line 2:
 
:Hi Michael, do you have an example page? I'm just worried that the page with the format description might look a little 'lost' as the format is only loosely based on the relatively obscure [http://www-cecpv.u-strasbg.fr/Documentations/lsf/html/lsf6.1_admin/G_jobarrays.html job array index format for LSF].
 
==Without Duck Typing==
Hi Neville, I noted this comment from your Algol solution:
:''Note: The closest concept that Algol 68 has to duck typing is the tagged union. If duck typing was available it could reduced the size of the code specimen, but would have lost some of Algol 68's strong type data security. ''
Thinking about it, you could form and use a list of ranges for what is to become each entry in the 'rangified' internal format, where each entry range is a pair of integers. It would then only be converted to the dash separated integer range form, or two comma separated digits, or one digit, in the routine to create a correctly formed string depending if the second number minus the first number in the range is: >= 2, or ==1, or == 0. --[[User:Paddy3118|Paddy3118]] 05:24, 16 July 2010 (UTC)
Anonymous user