does perl has switch case like in C??

Does perl has switch case like C++?
Next,
how do i store all these data that i have extracted into an array??
the data that I have extracted are
XB8B_Bmodule_MFB1_VT_Vt!MOSFET
XB8B_Bmodule_MFB2_VT_Vt!MOSFET
XB8B_Bmodule_MFB3_VT_Vt!MOSFET

The data are not fixed and they are extracted from a file

The source data is as follows where I have extracted the data from:

XB8B_Bmodule_MFB1_VT_Vt!MOSFET 10/1.5!R!V!+2.484027E+00!+2.486840E+00!+2.494738E+00!+2.481826E+00!+2.498665E+00
XB8B_Bmodule_MFB2_VT_Vt!MOSFET 10/1.6!R!V!+2.484340E+00!+2.491077E+00!+2.480577E+00!+2.475777E+00!+2.482094E+00
XB8B_Bmodule_MFB3_VT_Vt!MOSFET 10/1.8!R!V!+2.484071E+00!+2.479939E+00!+2.477249E+00!+2.475705E+00!+2.480875E+00
XB8B_Bmodule_MFB4_VT_Vt!MOSFET 10/5!R!V!+2.475608E+00!+2.492663E+00!+2.495399E+00!+2.497997E+00!+2.496347E+00
XB8B_Bmodule_MFB5_VT_Vt!MOSFET 5/5!R!V!+2.489002E+00!+2.488641E+00!+2.478360E+00!+2.486249E+00!+2.481316E+00
kopibeanAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

ozoCommented:
perldoc -q switch
0
MindoCommented:
The switch statement:
========================================
Using the for statement:
========================================
SWITCH: for ($where) {
               /In Card Names/     && do { push @flags, '-e'; last; };
               /Anywhere/          && do { push @flags, '-h'; last; };
               /In Rulings/        && do {                    last; };
               die "unknown value for form variable where: `$where'";
           }
========================================

========================================
Using the do{} block:
========================================
$amode =index.html do {
       if     ($flag & O_RDONLY) { "r" }       # XXX: isn't this 0?
       elsif  ($flag & O_WRONLY) { ($flag & O_APPEND) ? "a" : "w" }
       elsif  ($flag & O_RDWR)   {
           if ($flag & O_CREAT)  { "w+" }
           else                  { ($flag & O_APPEND) ? "a+" : "r+" }
       }
   };
========================================

========================================
Using the for with && and ||:
========================================
$dir =index.html 'http://www.wins.uva.nl/~mes/jargon';
   for ($ENV{HTTP_USER_AGENT}) {
       $page  =    /Mac/            && 'm/Macintrash.html'
                || /Win(dows )?NT/  && 'e/evilandrude.html'
                || /Win|MSIE|WebTV/ && 'm/MicroslothWindows.html'
                || /Linux/          && 'l/Linux.html'
                || /HP-UX/          && 'h/HP-SUX.html'
                || /SunOS/          && 's/ScumOS.html'
                ||                     'a/AppendixB.html';
   }
========================================

========================================
Using the for with && and ||:
========================================
$dir =index.html 'http://www.wins.uva.nl/~mes/jargon';
   for ($ENV{HTTP_USER_AGENT}) {
       $page  =    /Mac/            && 'm/Macintrash.html'
                || /Win(dows )?NT/  && 'e/evilandrude.html'
                || /Win|MSIE|WebTV/ && 'm/MicroslothWindows.html'
                || /Linux/          && 'l/Linux.html'
                || /HP-UX/          && 'h/HP-SUX.html'
                || /SunOS/          && 's/ScumOS.html'
                ||                     'a/AppendixB.html';
   }
========================================

========================================
Using the for and do{}:
========================================
for ($^O) {
        *struct_flock =index.html                do                           {
                                /bsd/  &&  \&bsd_flock
                                       ||
                            /linux/    &&    \&linux_flock
                                       ||
                          /sunos/      &&      \&sunos_flock
                                       ||
                  die "unknown operating system $^O, bailing out";
        };
    }

========================================

Some time ago i thought Perl is weird, now i think it's cool :-?

How to put data to an array?

This is array:

@myarray = ();

Add item to an array:

$item = "MyString";
push(@array, $item);

Access array item:

$string = $array[0];

I think you should buy a book on Perl. I bought one.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
kopibeanAuthor Commented:
Please look at my new question
how to specify which is which??(extracting data)"
I already have a book on perl
but i still have some parts which i dun understand in order to help me in my program
can u help me?
thanks
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Perl

From novice to tech pro — start learning today.