This repository contains PHP coding questions and their solutions, ranging from basic to advanced levels, to help you prepare for technical interviews.
- Swap Two Numbers Without Using a Third Variable
- Check if a Number is Prime
- Reverse a String Without Using Built-in Functions
- Find the Factorial of a Number (Using Recursion)
- Find the Second Largest Number in an Array
- Reverse a Linked List in PHP (Using Classes & OOP)
- Implement a Login System Using PHP & MySQL
- Implement an API in PHP (RESTful API Example)
- Each question will have its own file inside the
solutionsfolder. - Example:
/solutions/ - 01_swap_numbers.php - 02_prime_check.php - 03_reverse_string.php
- Clone this repository:
git clone https://github.com/patilsp/php-interview-prep.git
- Navigate to the project folder:
cd php-interview-prep - Run PHP scripts:
php solutions/01_swap_numbers.php
Feel free to add more PHP interview questions and improve existing solutions. Pull requests are welcome!
- Your Name (Santosh Patil)
Happy Coding! 🚀