Submission

Status:

Compilation Error

Subtask/Task Score:

Score: 0

User: agnes_chan

Problemset: กองส้ม

Language: cpp

Time: 0.000 second

Submitted On: 2026-05-05 23:33:49

#include <stdio.h>
#include <math.h>
int main(){
    int N,K;
    scanf("%d%d",&N,&K);
    float x = cbrt(3*K)-0.5;
    x -= (2*x*x*x+3*x*x+x-6*K)/(6*x*x+6*x+1)
    printf("%d",N-int(x));
}