PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Autres forums > Forum Programmation & Conception > comp.lang.c > Sorry, I don't know where to post this...
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
Sorry, I don't know where to post this...

Réponse
 
LinkBack Outils de la discussion
Vieux 28/11/2007, 22h31   #1
Mikhail Kovalev
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Sorry, I don't know where to post this...

Was hoping someone can me, does anyone know what programming
language this looks like:

@p @t\4@>@<Declare the procedure called |solve_choices|@>@;
procedure make_choices(@!knots:pointer);
label done;
var @!h:pointer; {the first breakpoint}
@!p,@!q:pointer; {consecutive breakpoints being processed}
@<Other local variables for |make_choices|@>@;
begin check_arith; {make sure that |arith_error=false|}
if internal[tracing_choices]>0 then
print_path(knots,", before choices",true);
@<If consecutive knots are equal, join them explicitly@>;
@<Find the first breakpoint, |h|, on the path;
insert an artificial breakpoint if the path is an unbroken cycle@>;
p:=h;
repeat @<Fill in the control points between |p| and the next
breakpoint,
then advance |p| to that breakpoint@>;
until p=h;
if internal[tracing_choices]>0 then
print_path(knots,", after choices",true);
if arith_error then @<Report an unexpected problem during the choice-
making@>;
end;

Thanks!=)
  Réponse avec citation
Vieux 28/11/2007, 22h34   #2
Malcolm McLean
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Sorry, I don't know where to post this...

comp.programming.
  Réponse avec citation
Vieux 28/11/2007, 22h35   #3
jacob navia
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Sorry, I don't know where to post this...

Mikhail Kovalev wrote:
> Was hoping someone can me, does anyone know what programming
> language this looks like:
>
> @p @t\4@>@<Declare the procedure called |solve_choices|@>@;
> procedure make_choices(@!knots:pointer);
> label done;
> var @!h:pointer; {the first breakpoint}
> @!p,@!q:pointer; {consecutive breakpoints being processed}
> @<Other local variables for |make_choices|@>@;
> begin check_arith; {make sure that |arith_error=false|}
> if internal[tracing_choices]>0 then
> print_path(knots,", before choices",true);
> @<If consecutive knots are equal, join them explicitly@>;
> @<Find the first breakpoint, |h|, on the path;
> insert an artificial breakpoint if the path is an unbroken cycle@>;
> p:=h;
> repeat @<Fill in the control points between |p| and the next
> breakpoint,
> then advance |p| to that breakpoint@>;
> until p=h;
> if internal[tracing_choices]>0 then
> print_path(knots,", after choices",true);
> if arith_error then @<Report an unexpected problem during the choice-
> making@>;
> end;
>
> Thanks!=)


This looks like Knuth's literate programming language.

It is a way of writing the documentation AND the program. A preprocessor
separates the code from the Pascal and generates a compilable
program, and another preprocessor formats the code.

Code is processed by numbered blocks, for instance above
> @<Other local variables for |make_choices|@>@;

refers to a block where all those variables are defined.

This allows the code design from a top down manner.

To get more information google for "Literate programming"
"web" and "tangle", or look at the papers by Knuth on literate programming.

--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32
  Réponse avec citation
Vieux 28/11/2007, 22h41   #4
Walter Roberson
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Sorry, I don't know where to post this...

In article <726c0b5a-d8e4-4387-88c8-ba87fac0843c@e1g2000hsh.googlegroups.com>,
Mikhail Kovalev <mikhail_kovalev@mail.ru> wrote:
>Was hoping someone can me, does anyone know what programming
>language this looks like:


>@p @t\4@>@<Declare the procedure called |solve_choices|@>@;
>procedure make_choices(@!knots:pointer);


Possibly MetaPost ?
--
"Any sufficiently advanced bug is indistinguishable from a feature."
-- Rich Kulawiec
  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 02h08.


Édité par : vBulletin® version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières ©2000-2008
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,08914 seconds with 12 queries