From: Tomas Szepe <szepe@dragon.cz>
To: Daniel Phillips <phillips@arcor.de>
Cc: Ville Herva <vherva@niksula.hut.fi>,
Thunder from the hill <thunder@ngforever.de>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH -ac] Panicking in morse code, v2
Date: Sat, 20 Jul 2002 16:55:04 +0200 [thread overview]
Message-ID: <20020720145504.GD7333@louise.pinerecords.com> (raw)
In-Reply-To: <E17Vv4I-0000kh-00@starship>
> > > Hi,
> > >
> > > On Sat, 20 Jul 2002, Daniel Phillips wrote:
> > > > Unfortunately, this code is too useful to ignore.
> > >
> > > I think it's also a nice-to-have for 2.5.
> >
> > Okay, maybe it's just me being too lazy and ignorant to teach myself morse
> > code...
>
> Then teach it to a script, call it "unmorse" ;-)
>
> echo dit dit dit dah dah dah dit dit dit | unmorse
Try this on for size:
/* dorssel.c, 1998 IOCCC entry
* Frans van Dorsselaer <frans@biabv.com>
*/
#include<stdio.h>
#include<string.h>
main()
{
char*O,l[999]="'`acgo\177~|xp .-\0R^8)NJ6%K4O+A2M(*0ID57$3G1FBL";
while(O=fgets(l+45,954,stdin)){
*l=O[strlen(O)[O-1]=0,strspn(O,l+11)];
while(*O)switch((*l&&isalnum(*O))-!*l){
case-1:{char*I=(O+=strspn(O,l+12)+1)-2,O=34;
while(*I&3&&(O=(O-16<<1)+*I---'-')<80);
putchar(O&93?*I&8||!(I=memchr(l,O,44))?'?':I-l+47:32);
break;
case 1: ;}*l=(*O&31)[l-15+(*O>61)*32];
while(putchar(45+*l%2),(*l=*l+32>>1)>35);
case 0: putchar((++O,32));}
putchar(10);}
}
next prev parent reply other threads:[~2002-07-20 14:52 UTC|newest]
Thread overview: 58+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-07-19 5:13 [PATCH -ac] Panicking in morse code Andrew Rodland
2002-07-19 5:29 ` William Lee Irwin III
2002-07-19 16:36 ` Thorsten Kranzkowski
2002-07-19 17:00 ` Andrew Rodland
2002-07-19 17:27 ` Eli Carter
2002-07-19 17:32 ` Andrew Rodland
2002-07-19 23:02 ` [PATCH -ac] Panicking in morse code, v2 Andrew Rodland
2002-07-20 10:58 ` Daniel Phillips
2002-07-20 11:19 ` Thunder from the hill
2002-07-20 13:22 ` Ville Herva
2002-07-20 14:18 ` Daniel Phillips
2002-07-20 14:55 ` Tomas Szepe [this message]
2002-07-20 16:05 ` Daniel Phillips
2002-07-20 19:51 ` Thunder from the hill
2002-07-20 0:35 ` [PATCH -ac] Panicking in morse code Alan Cox
2002-07-20 0:39 ` Andrew Rodland
2002-07-20 0:48 ` Thunder from the hill
2002-07-25 12:51 ` Bill Davidsen
2002-07-26 3:43 ` Daniel Phillips
2002-07-26 4:47 ` Daniel Phillips
2002-07-26 4:52 ` jdow
2002-07-26 5:13 ` Daniel Phillips
2002-07-26 13:50 ` Bill Davidsen
2002-07-26 13:38 ` Bill Davidsen
2002-07-26 14:39 ` Richard B. Johnson
2002-07-26 20:09 ` Bill Davidsen
2002-07-26 23:25 ` Jens Schmidt
2002-07-27 2:05 ` Albert D. Cahalan
2002-07-27 4:00 ` Andrew Rodland
[not found] ` <200207270526.g6R5Qw942780@saturn.cs.uml.edu>
2002-07-27 5:57 ` Speaker twiddling [was: Re: Panicking in morse code] Andrew Rodland
2002-07-27 9:46 ` Daniel Phillips
2002-07-27 12:57 ` David D. Hagood
2002-07-27 15:45 ` Andrew Rodland
2002-07-29 17:47 ` Pavel Machek
2002-07-29 22:02 ` Ray Friess
2002-07-29 17:49 ` Pavel Machek
2002-07-29 20:35 ` Albert D. Cahalan
2002-07-29 21:08 ` Pavel Machek
2002-07-27 18:56 ` Albert D. Cahalan
2002-07-27 19:44 ` Ville Herva
2002-07-27 22:40 ` Alan Cox
2002-07-27 21:35 ` Ville Herva
2002-07-31 15:20 ` Thunder from the hill
2002-07-27 21:40 ` Ryan Anderson
2002-07-28 10:26 ` Lars Magne Ingebrigtsen
2002-07-29 20:03 ` Albert D. Cahalan
2002-08-13 17:20 ` Mark H. Wood
2002-07-27 4:04 ` [PATCH -ac] Panicking in morse code Andrew Rodland
2002-07-29 11:50 ` Bill Davidsen
2002-07-29 12:34 ` Richard B. Johnson
2002-07-29 19:57 ` Albert D. Cahalan
2002-07-31 17:54 ` Bill Davidsen
2002-07-20 21:32 ` [PATCH -ac] Panicking in morse code v3 Andrew Rodland
2002-07-21 8:49 ` Brad Hards
2002-07-21 9:08 ` Russell King
2002-07-21 10:50 ` Zwane Mwaikambo
2002-07-21 15:43 ` Daniel Phillips
2002-07-22 17:18 ` Andrew Rodland
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20020720145504.GD7333@louise.pinerecords.com \
--to=szepe@dragon.cz \
--cc=linux-kernel@vger.kernel.org \
--cc=phillips@arcor.de \
--cc=thunder@ngforever.de \
--cc=vherva@niksula.hut.fi \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox