Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
Learning AWK Programming

You're reading from   Learning AWK Programming A fast, and simple cutting-edge utility for text-processing on the Unix-like environment

Arrow left icon
Product type Paperback
Published in Mar 2018
Publisher Packt
ISBN-13 9781788391030
Length 416 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
 Kalkhanda Kalkhanda
Author Profile Icon Kalkhanda
Kalkhanda
Arrow right icon
View More author details
Toc

Table of Contents (16) Chapters Close

Title Page
Dedication
Packt Upsell
Contributors
Preface
1. Getting Started with AWK Programming FREE CHAPTER 2. Working with Regular Expressions 3. AWK Variables and Constants 4. Working with Arrays in AWK 5. Printing Output in AWK 6. AWK Expressions 7. AWK Control Flow Statements 8. AWK Functions 9. GNU's Implementation of AWK – GAWK (GNU AWK) 10. Practical Implementation of AWK Index

Understanding regular expression metacharacters


When we use special characters in regular expressions, they are called metacharacters because they have a special meaning. They enhance the flexibility, power, and usage of regular expressions. Now, we will discuss the list of metacharacters in regular expressions. All characters, that are not either metacharacters or escape sequences, match themselves in regular expressions. Let's understand each of them in detail.

Quoted metacharacter

A regular expression consisting of a literal or character(letter or digit) is a basic regular expression thatmatches itself.Sometimes, if we need to usethe literal meaning of a metacharacter in a regular expression,weprecede it with a backslash.If a character is preceded by a single backslash, \, we say the character is quoted.Quoting suppresses the special meaning of a character when matching. For example,if we wantto match the dollar sign, $, in a string, we need to quote it as follows:

$ echo -e "500$\n500INR...
lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at £13.99/month. Cancel anytime
Visually different images