Search notes:

Perl operator: ++ (plus plus)

use warnings;
use strict;

use feature 'say';


# Incrementing undefined

my      $undefined        ;
        $undefined ++     ;
say     $undefined        ;  #  1

my      $another_undefined;
     ++ $another_undefined;
say     $another_undefined;  #  1


# Incrementing strings

my      $string = 'y'     ;
say     $string++         ;  #  y
say     $string++         ;  #  z
say     $string++         ;  #  aa

my      $string_2 = 'zZz' ;
        $string_2 ++      ;
say     $string_2         ;  #  aaAa       (Note upper and lower case)
Github repository about-perl, path: /operators/++.pl

See also

Perl operators

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/developm...', 1758200707, '216.73.216.150', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/development/languages/Perl/operators/plusplus(64): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78