From: Sergey Shilov <hsvhome@mail.ru>
To: sysadmins@lists.altlinux.org
Subject: Re: [Sysadmins] awk
Date: Wed, 30 Jul 2008 23:51:40 +0300
Message-ID: <200807302351.40333.hsvhome@mail.ru> (raw)
In-Reply-To: <200807302112.07968.ledest@gmail.com>
> Перед if лишняя {
>
> Но код, мягко говоря, "от Java-кодера" (без обид, плиз):)
Комплимент! На Java никогда не писал.
Приведенный пример (с поправкой на скобку):
- рабочий;
- реализующий задачу "в лоб";
- умышленно избыточный для читабельности;
- однострочный для из консоли пускабельности;
- без претензии на конгениальность и академичность.
Академию на awk в студию :-)
Без awk (как на мой взгляд)
echo "aaa_bbb_ccc_bad" | grep -o _[bc] | sed -n 2p
--
С уважением
Сергей Шилов.
prev parent reply other threads:[~2008-07-30 20:51 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-07-29 11:25 Aleksey E. Birukov
2008-07-29 20:11 ` Sergey Shilov
2008-07-29 20:57 ` Led
2008-07-30 7:16 ` Aleksey E. Birukov
2008-07-30 9:41 ` Sergey Shilov
2008-07-30 10:27 ` Led
2008-07-30 15:03 ` Шилов Сергей
2008-07-30 16:58 ` Aleksey E. Birukov
2008-07-30 17:17 ` Alexey Borisenkov
2008-07-30 20:10 ` Sergey Shilov
2008-07-30 18:12 ` Led
2008-07-30 20:51 ` Sergey Shilov [this message]
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=200807302351.40333.hsvhome@mail.ru \
--to=hsvhome@mail.ru \
--cc=sysadmins@lists.altlinux.org \
/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
ALT Linux sysadmins discussion
This inbox may be cloned and mirrored by anyone:
git clone --mirror http://lore.altlinux.org/sysadmins/0 sysadmins/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 sysadmins sysadmins/ http://lore.altlinux.org/sysadmins \
sysadmins@lists.altlinux.org sysadmins@lists.altlinux.ru sysadmins@lists.altlinux.com
public-inbox-index sysadmins
Example config snippet for mirrors.
Newsgroup available over NNTP:
nntp://lore.altlinux.org/org.altlinux.lists.sysadmins
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git