1. Home
  2. Computing & Technology
  3. Perl

Perl string uc() function - Quick Tutorial
How to use the string uc() function

From About.com

$STRING = uc($STRING);
Perl's uc() function takes a string, makes the entire thing uppercase, and then returns the new string.
$myWord = 'word';
$myUpperWord = uc($myWord);
First, $myWord is set to a value of 'word', then the uc() function is run on $myWord. The uc() function takes the entire string $myWord and converts it to it's uppercase equivalent. The value of $myUpperWord is then equal to 'WORD'.
More Perl Quick Tips
Explore Perl
About.com Special Features

Stay connected and entertained with reviews on tips on the latest HDTVs, cellphones and more. More >

Easy ways to connect two computers for networking purposes. More >

  1. Home
  2. Computing & Technology
  3. Perl
  4. Programming Perl
  5. Perl uc function reference - learn how to use Perl's uc() function in this quick tutorial.

©2009 About.com, a part of The New York Times Company.

All rights reserved.