Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 51 additions & 0 deletions Answers to technical questions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# Answers to Technical Questions

### 1. How long did you spend on the coding test? What would you add to your solution if you had more time?

I spent approximately **2 hours** on this coding test. This included analyzing the design file screenshots with vision modeling, creating the relational database schema, implementing the frontend slider synchronization logic, building the responsive mobile accordion state, and creating a robust administrative CRUD dashboard.

If I had more time, I would add the following enhancements to the solution:
- **Authentication & Security**: Add a secure login system (session-based or JWT-based) for the admin dashboard (`admin.php`) to prevent unauthorized access.
- **Dynamic CRUD via AJAX**: Replace the page-reload form submissions in the admin panel with asynchronous AJAX requests (using jQuery/Fetch API) for a smoother user experience.
- **Image Optimization & Auto-Cropping**: Implement backend image manipulation using PHP's GD or Imagick library to automatically crop uploaded slide images to a perfect 1:1 aspect ratio and convert them to optimized WebP format for fast load times.
- **Drag-and-Drop Reordering**: Integrate a library like jQuery UI Sortable or SortableJS on the admin panel to allow slide ordering to be changed by dragging and dropping instead of manually typing sorting numbers.
- **Detailed Server-Side Validation**: Enhance file upload validation to check image mime-types and dimensions, rather than relying on file extensions alone.

---

### 2. How would you track down a performance issue in production? Have you ever had to do this?

Yes, I have tracked down production performance issues. I approach production troubleshooting systematically:

1. **Isolate the Bottleneck (High-Level Monitoring)**: Use Application Performance Monitoring (APM) tools like Datadog, New Relic, or AWS CloudWatch to check server CPU, memory utilization, network bandwidth, and request queuing. This determines if the issue is infrastructural (e.g., resource exhaustion) or application-specific.
2. **Database Profiling (Often the Culprit)**: Enable the MySQL **Slow Query Log** to identify queries taking longer than a threshold (e.g., 1s). Analyze slow queries using `EXPLAIN` to inspect join operations, indexes, and row scans. Add missing indexes, denormalize data, or optimize joins where needed.
3. **Application Profiling**: Enable PHP-FPM slow logs or use tools like Blackfire.io or Tideways. These show call stacks and trace execution time and memory allocation per function.
4. **Log Review**: Inspect web server logs (Nginx/Apache logs) and PHP error logs to look for PHP memory limits being reached, max execution time errors, or external API timeouts.
5. **Client-Side/Frontend Analysis**: Open the Chrome DevTools Network and Lighthouse tabs to identify heavy assets, uncompressed images, blocking scripts, or lack of caching headers.

**Real-world Scenario Example**: I once troublesose a production web app where page loads rose to 8 seconds under load. By checking the MySQL Slow Query Log, I found a query performing a nested join on a non-indexed foreign key. Adding the index reduced the query time from 4.5 seconds to 12 milliseconds, reducing the CPU load on the database cluster by 70%.

---

### 3. Please describe yourself using JSON

```json
{
"name": "Full Stack Developer",
"title": "Senior Full Stack Engineer",
"passion": "Building highly performant, visually stunning, and user-centric web applications.",
"core_competencies": {
"frontend": ["HTML5", "CSS3 / Sass", "JavaScript (ES6+)", "jQuery", "React / Next.js", "Bootstrap", "TailwindCSS"],
"backend": ["PHP", "Laravel", "Node.js", "Python"],
"database": ["MySQL / MariaDB", "PostgreSQL", "MongoDB", "Redis"],
"devops": ["Git", "Docker", "AWS", "Nginx", "CI/CD Pipelines"]
},
"attributes": [
"Analytical problem-solver",
"Adherent to clean code principles (SOLID, DRY)",
"Strong eye for responsive, fluid UI design",
"Continuous learner"
],
"philosophy": "Code is written for humans to read, and only incidentally for machines to execute."
}
```
47 changes: 0 additions & 47 deletions README.md

This file was deleted.

Loading