Php://stdin So how input is provided, is it in file or CLI...?

Here in php version of input code to solve the algo

I see this

$_fp = fopen(“php://stdin”,“r”);

So how input is provided, is it in file or CLI…?

I am have experience in PHP adv topics like design patterns but first time meet this…well?

neither. php://stdin is the input stream, but no assumption is made how that stream is created. generally, stdin/stdout/stderr make most sense when used in the CLI.

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.