27/10/2021 23:49 
	
	
	Código PHP:
PegarPorcentagem(string1, string2) { return (string2 * string1) / 100; } 
Código PHP:
new preco = PegarPorcentagem(20, 100); 
Com o código, a variável preco irá receber 20% de 100.
 
	   
	
|  | 
| Mensagem neste Tópico | 
| Porcentagem - por Levi.M - 27/10/2021 21:56 RE: Porcentagem - por ipsLuan - 27/10/2021 23:49 RE: Porcentagem - por xbruno1000x - 28/10/2021 00:57 RE: Porcentagem - por Levi.M - 28/10/2021 08:49 |