Catch up on stories from the past week (and beyond) at the Slashdot story archive


Forgot your password?
Check out the new SourceForge HTML5 internet speed test! No Flash necessary and runs on all devices. ×
User Journal

Journal Journal: A Perl Lesson for the Day 1

If you have a block of quoted text inside the single-quoting operator q(), a backslash preceding a '(' or ')' (or whatever delimiter characters you have chosen for q()), will be parsed as an escape on that delimiter character. Therefore, you must escape any literal backslash if it appears before '(' or ')'.


#!/usr/bin/perl -w
print q(
This is a test... x(1), x\(2\), x\[3\], x\\(4\\).

The rationale for this undocumented Perl feature is reasonable. The q() operator will ignore balanced pairs of delimiter characters that appear in the enclosed text, but it is sometimes necessary to write text that contains unbalanced delimiters. To make that possible, the q() operator must recognize the escape on its delimiters.

User Journal

Journal Journal: Shiner B.A.S.H 1

Completed my longest ride to date: 93.8 miles,
from Katy to Shiner in exactly 6 hours,
including rest stops. Ride time was 5:10,
avg. speed 18.2 mph.

Weather turned out to be perfect, after a week
of thunderstorms. Most riders were charged up
and in high spirits with the sudden improvement
in the weather. A light breeze out of the north
neither helped nor hindered the westbound riders.

The course was good, except for a 4-mile stretch
west of Wallis where the pavement had been
removed; in other words, GRAVEL. I'm glad that
I had installed Gatorskins last week; a lot of
riders got flats in that stretch. The course
was mostly flat for the first 60 miles, then
turned into rolling hills for the last 33 miles.
Nothing too tough; I stayed in the saddle and
simply downshifted. Never had to use the granny

The post-ride event was rather disappointing.
Free beer, but no place to sit and no shade.
By noon, the temperature had climbed into the
80's, the air was still humid from the previous
days' rainfall and, off the bike, there was
very little breeze. Next year, it would be
nice to have our own tent and chairs (if I
can talk the wife into bringing them).

Slashdot Top Deals

Steve Jobs said two years ago that X is brain-damaged and it will be gone in two years. He was half right. -- Dennis Ritchie