igor-kachko/otus-composer-package

There is no license information available for the latest version (1.0.5) of this package.

Installs: 18

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 0

Open Issues: 0

pkg:composer/igor-kachko/otus-composer-package

1.0.5 2024-11-24 13:40 UTC

This package is not auto-updated.

Last update: 2026-01-18 19:23:10 UTC


README

  • getLength(string $str) - Узнать длину строки
  • checkParenthesis(string $str) - Проверка корректности открытых и закрытых скобок в строке

Установка

composer require igor-kachko/otus-composer-package

Использование

<?php  
  
$processor = new StringProcessor();  
echo $processor->getLength('my string'); // 9

try {
    $processor->checkParenthesis("(1+2))(text())))()()()");
    echo "Все хорошо";
} catch(\Exception $e) (
    echo $e->getMessage();
)