You want to use Drupal 7 but you are unsure which PHP version is supported.
The recommended version of PHP for Drupal 7 is PHP version 5.4 although older versions are supported with caveats.
Our recommendation is that is you absolutely have to, use version 5.6. Otherwise try to use version 7.2.
Here is a table of all PHP version support for Drupal 7:
|PHP version||Drupal 7|
|5.2||5.2.5+ (see note 1 below)|
|5.4||yes – minimum recommended|
|7.0||yes (see note in link below)|
|7.1||yes (see note in link below)|
|7.2||no (see note in link below)|
(1) For Drupal 7, versions of PHP 5.2.4 that include backported security patches also meet the requirements. The PHP version included with Ubuntu 8.04 is the most common example of this.
This table was directly taken from the Drupal website link below: