Junior — Middle
Can you tell about a specific project you worked on?
sobes.tech AI
Answer from AI
In one of the projects, I developed a web application using Python with Flask. The task was to create a REST API for managing user tasks. I implemented data models using SQLAlchemy, set up routes for CRUD operations, and ensured authentication via JWT. I also wrote a module for sending email notifications when the task status changes.
Here's an example of a simple route in Flask:
from flask import Flask, jsonify, request
app = Flask(__name__)
tasks = []
@app.route('/tasks', methods=['POST'])
def create_task():
data = request.json
task = {'id': len(tasks) + 1, 'title': data['title'], 'done': False}
tasks.append(task)
return jsonify(task), 201
if __name__ == '__main__':
app.run()