Returning a value
#!/usr/bin/perl use Inline 'C'; say "7 + 9 = ", add(7, 9); __END__ __C__ int add(int x, int y) { return x + y; }
- Output:
16
#!/usr/bin/perl use Inline 'C'; say "7 + 9 = ", add(7, 9); __END__ __C__ int add(int x, int y) { return x + y; }
16