コンテストの制限時間が終了しました。
以降も提出を行うことができますが、順位集計には反映されません。
以降も提出を行うことができますが、順位集計には反映されません。
ソースコード
select AGE_NAME as "年齢階層", sum(A.TARGET_POP) as "5時間未満", B.s as "5時間以上6時間未満" , C.s as "6時間以上7時間未満", D.s as "7時間以上8時間未満", E.s as "8時間以上9時間未満",
F.s as "9時間以上", G.s as "不詳"
from SLEEP_TIME_DTL as A
inner join (
select AGE_CODE, sum(SLEEP_TIME_DTL.TARGET_POP) as s
from SLEEP_TIME_DTL
where TIME_CODE = 130
group by AGE_CODE
) as B on A.AGE_CODE = B.AGE_CODE
inner join (
select AGE_CODE, sum(SLEEP_TIME_DTL.TARGET_POP) as s
from SLEEP_TIME_DTL
where TIME_CODE = 140
group by AGE_CODE
) as C on A.AGE_CODE = C.AGE_CODE
inner join (
select AGE_CODE, sum(SLEEP_TIME_DTL.TARGET_POP) as s
from SLEEP_TIME_DTL
where TIME_CODE = 150
group by AGE_CODE
) as D on A.AGE_CODE = D.AGE_CODE
inner join (
select AGE_CODE, sum(SLEEP_TIME_DTL.TARGET_POP) as s
from SLEEP_TIME_DTL
where TIME_CODE = 160
group by AGE_CODE
) as E on A.AGE_CODE = E.AGE_CODE
inner join (
select AGE_CODE, sum(SLEEP_TIME_DTL.TARGET_POP) as s
from SLEEP_TIME_DTL
where TIME_CODE = 170
group by AGE_CODE
) as F on A.AGE_CODE = F.AGE_CODE
inner join (
select AGE_CODE, sum(SLEEP_TIME_DTL.TARGET_POP) as s
from SLEEP_TIME_DTL
where TIME_CODE = 180
group by AGE_CODE
) as G on A.AGE_CODE = G.AGE_CODE
inner join AGE_GRP
on A.AGE_CODE = AGE_GRP.AGE_CODE
where A.TIME_CODE = 120
group by A.AGE_CODE
order by A.AGE_CODE;
メッセージ
テストケース(通過数/総数)
2/2
状態
メモリ使用量
データパターン1
AC
94 MB
データパターン2
AC
96 MB