Editorial for Mừng giao diện mới
Remember to use this editorial only when stuck, and not to copy-paste code from it. Please be respectful to the problem author and editorialist.
Submitting an official solution before solving the problem yourself is a bannable offence.
Submitting an official solution before solving the problem yourself is a bannable offence.
Author:
Subtask 1:
Ta chỉ cần làm đúng như những gì đề bài yêu cầu là được. Độ phức tạp thuật toán:
Subtask 2:
Ta biểu diễn hai mảng dưới dạng hai đa thức:
•
•
Khi đó, ta dễ thấy đa thức biểu diễn mảng
Edit: Thuật toán Karatsuba với toán tử OR có thể nhân hai đa thức trong
Comments