Yes, it is legal, but it's important to write my assignment for me use the work ethically and avoid academic misconduct