Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 09-19-2002, 05:05 PM   #1
LQ Newbie
Registered: Sep 2002
Location: Montreal
Distribution: Mandrake 8.2
Posts: 10

Rep: Reputation: 0
awk question (mandrake 8.2)


I'v got a problem with an "if":

if (last_pitch ~ /[A-G]/) last_oc = length(last_pitch) * -1
else last_oc = length(last_pitch) - 1

last_pitch can be any characters from AA-GG, A-G, a-g, or aa-gg.
The "if" doesn't seem to be able to tell if the character(s) in last_pitch are upper-case or lower-case; that is, it always executes the first line, and never gets to the "else". A similar problem also occurs elsewhere in the program---it can't tell upper-case from lower-case. Is there a special way to indicate this?



Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
awk question puishor Programming 2 08-26-2005 10:44 AM
awk question denalitastic Linux - Newbie 1 06-07-2005 11:42 AM
AWK question paraiso Linux - Newbie 5 05-12-2005 02:37 PM
awk question jonlake Linux - Software 2 05-04-2005 04:58 PM
awk question dilberim82 Programming 2 10-01-2003 08:12 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:00 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration