Alberta226 has asked for the wisdom of the Perl Monks concerning the following question:
Hiya PerlMonks!
I have this code:
It is suppose to remove the first three sets of information from the list leaving purple, pink and white. Instead I get oranglepurplepinkwhite Any ideas?#!/usr/bin/perl use warnings; use strict; ############################################################# # Array splicing # Removing elements then returning more than one element at a time ############################################################# my @colors = ("red", "blue", "orange", "purple", "pink", "white"); splice(@colors, 0, 2); print @colors;
Back to
Seekers of Perl Wisdom