DataMuseum.dk

Presents historical artifacts from the history of:

CR80 Hard and Floppy Disks

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about CR80 Hard and Floppy Disks

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦459433fa2⟧ TextFile

    Length: 716 (0x2cc)
    Types: TextFile
    Names: »SORT.S«

Derivation

└─⟦b21be6f3b⟧ Bits:30005082 8" CR80 Floppy CR80FD_0036 ( CR/D/3143 KLP & KMO C-KURSUS + C JOBFILER 861127 Volume MOVEFL RAM TEST css/709 #0000-7fff V24+SCM )
    └─⟦95f1eafb2⟧ 
        └─ ⟦this⟧ »GR1.D!SORT.D!SORT.S« 
└─⟦c25823ad8⟧ Bits:30005089 8" CR80 Floppy CR80FD_0044 ( @*FLOPPY C )
    └─⟦feb1d529a⟧ 
        └─ ⟦this⟧ »GR1.D!SORT.D!SORT.S« 

TextFile

#include <std.h>

main()

{
  unsigned int newno;
  struct elem
  {
    struct elem *next;
    unsigned int field;
  } *new, *temp;

  new = temp = nalloc (sizeof (*new), NULL);
  new->field = -1;

  putfmt("ENTER NUMBER SEPERATED BY <CR> - '-1' = QUIT\n");
  getfmt ("%i", &newno);
  while (newno != -1)
  {
    while ((temp->next) && (temp->next->field < newno))
      temp = temp->next;

    temp->next = nalloc (sizeof(*temp), temp->next);
    temp->next->field = newno;

    temp = new;
    putfmt("ENTER NUMBER SEPERATED BY <CR> - '-1' = QUIT\n");
    getfmt("%i", &newno);
  }

  for (temp=new->next;(temp->next);putfmt ("%i\n", temp->field),temp=temp->next);
  putfmt ("%i\n", temp->field);

  return (1);
}