@php use App\Helpers\StudentHelper; $logoPath = StudentHelper::collegeLogo(); $ctitle = StudentHelper::collegeCtitle(); $ptitle = StudentHelper::collegePtitle(); $logoExists = $logoPath && file_exists(storage_path('app/public/' . $logoPath)); // ✅ completed flag (based on existing $previousAnswer behavior) $isCompleted = $is_submitted ?? false; $IS_COMPLETED = $isCompleted; $rawAnswer = $previousAnswer ?? ''; // if stored as
..., extract code only
$rawAnswer = preg_replace('#^|$#i', '', trim($rawAnswer));
// decode entities: < -> < etc
$rawAnswer = html_entity_decode($rawAnswer, ENT_QUOTES | ENT_HTML5, 'UTF-8');
// normalize line endings
$rawAnswer = str_replace(["\r\n", "\r"], "\n", $rawAnswer);
@endphp
Checking 2 visible sample tests & 2 secret bonus tests.
| Test Case | Input | Expected Output | Your Output | Result |
|---|