#!/usr/bin/perluse warnings;use strict;my @lines = ("C", "B", "A", "E", "D");while (my $line = shift @lines) { last if $line eq 'A';}print "@lines";