Find two numbers with sum and product both same as N | Function to return the smallest string ; Not possible ; find a and b ; Driver Code
< ? php function findAandB ( $ N ) { $ val = $ N * $ N - 4.0 * $ N ; if ( $ val < 0 ) { echo " NO " ; return ; } $ a = ( $ N + sqrt ( $ val ) ) / 2.0 ; $ b = ( $ N - sqrt ( $ val ) ) / 2.0 ; echo " a = " ▁ , ▁ $ a , ▁ " " ; STRNEWLINE TABSYMBOL echo ▁ " b = " ▁ , ▁ $ b , ▁ " " } $ N = 69.0 ; findAandB ( $ N ) ; ? >