#!/usr/bin/perl use strict; use warnings; my $sample = \&test(); sub test{ print "Hallo\n"; }