from research import *
s=begin(980,'Counts before rounded date labels','What fails if the capacity is formed from independently rounded dates?',{},['C954','C955','C978'])
q=lambda n:5*((n+2)//5);B=json.loads((ROOT/'model/sp_birth_regeneration.json').read_text())['births'];a=[5,7,8];count_first=[q(B[i]-2893+1) for i in a];date_first=[q(B[i])-q(2893)+1 for i in a]
finish(s,{'count_first':count_first,'date_labels_first':date_first,'status':'diagnostic operation comparison; not a canonical Rounded date table'},'Rounding counts gives845/720/655; rounding the two date labels first gives846/716/651. Resolving the interval and counting convention before rounding is essential.','Trace the known SP residual through the cap’s changed rows.',{'count_values':count_first==[845,720,655],'date_values':date_first==[846,716,651],'different_operations':count_first!=date_first})
