We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2a75bfe commit 7fefac2Copy full SHA for 7fefac2
SQL/SQL-50/Percentage_of_Users_Attended_a_Contest.sql
@@ -0,0 +1,5 @@
1
+select contest_id,
2
+round(count(distinct user_id) / (select count(user_id) from Users) * 100, 2) as percentage
3
+from Register
4
+group by contest_id
5
+order by percentage desc, contest_id asc;
0 commit comments