Copyright © tutorialspoint.com

# PERL getpgrp Function

## Syntax

getpgrp EXPR getpgrp

## Definition and Usage

Returns the process group for the process ID specified by EXPR, or the current process group if none is specified.

## Return Value

- Process group ID

## Example

Try out following example:

    #!/usr/bin/perl

    $pgid = getpgrp();

    print "Current process Group ID $pgid\n";

Copyright © tutorialspoint.com