Newsgroups: fj.lang.perl
Path: galaxy.trc.rwcp.or.jp!coconuts.jaist!wnoc-tyo-news!etlnews.etl.go.jp!news.trc!nf8.iij.ad.jp!nr0.iij.ad.jp!news.iij.ad.jp!othp1.sci.jri.co.jp!othp1!mishima
From: mishima@osa.sci.jri.co.jp (Masahiro Mishima)
Subject: Re: cost for regexp matching
In-Reply-To: jun@nih.go.jp's message of 23 May 1997 04:00:32 GMT
Content-Type: text/plain; charset=ISO-2022-JP
Message-ID: <MISHIMA.97May23160533@oppc1.osa.sci.jri.co.jp>
Sender: news@osa.sci.jri.co.jp (NetNews)
Nntp-Posting-Host: oppc1
Organization: The Japan Research Institute,LTD.,JAPAN
References: <JUN.97May23130032@watson.nih.go.jp>
Mime-Version: 1.0 (generated by tm-edit 7.59)
Date: Fri, 23 May 1997 07:05:33 GMT
Lines: 22
Xref: galaxy.trc.rwcp.or.jp fj.lang.perl:1996
X-originally-archived-at: http://galaxy.rwcp.or.jp/text/cgi-bin/newsarticle2?ng=fj.lang.perl&nb=1996&hd=a
X-reformat-date: Mon, 18 Oct 2004 15:18:22 +0900
X-reformat-comment: Tabs were expanded into 4 column tabstops by the Galaxy's archiver. See http://katsu.watanabe.name/ancientfj/galaxy-format.html for more info.

In article <JUN.97May23130032@watson.nih.go.jp> jun@nih.go.jp (ISHIKAWA Jun) writes:

> $B$"$kJ8;zNs$NCf$K$"$kJ8;z$,$$$/$D4^$^$l$k$+$rD4$Y$k$?$a$K!"(B
> $B<!$N$h$&$J$3$H$r$d$C$F$$$^$9(B($B<B:]$K$O?t@i!A?tK|J8;z(B)$B!'(B
> 
> $seq = "ATCTCCCACATCAAGGCCTGGGCC";
> $count = 0;
> for ($i = 0; $i < length($seq); $i++) {
>     $count++ if substr($seq,$i,1) eq "G" || substr($seq,$i,1) eq "C";
> }
($BCfN,(B)
> $B$^$?!"$3$N$h$&$JL\E*$rC#$9$k$?$a$K!"(B
> $B$h$j$h$$J}K!$,$"$j$^$7$?$i!"(B
> suggest$B$7$F$$$?$@$1$k$H$"$j$,$?$$$G$9!#(B

$seq = "ATCTCCCACATCAAGGCCTGGGCC";
$count = $seq =~ tr/GC//;

--
$B!J3t!KF|K\Am8&%7%9%F%`%=%j%e!<%7%g%s!!Bg:e%=%j%e!<%7%g%s;v6HIt(B
$B!!!!!!%M%C%H%o!<%/!&%3%s%T%e!<%F%#%s%0!&%G%#%S%8%g%s!!Bh#2%0%k!<%W(B
$B!!!!!!;0Eh!!@590(B
