Student with greater average grades by major – Artificial Intelligence
Tables and data: CREATE TABLE major ( id INT PRIMARY KEY, name VARCHAR(200) ); insert into major values (101, 'Computing'), (102, 'Arquitecture'); CREATE TABLE student ( id INT PRIMARY KEY, name VARCHAR(200), major_id INT, foreign key(major_id) references major(id) ); insert…