考試總結 noip模擬9

2022-09-09 07:42:08 字數 1241 閱讀 9472

所以現在才更新

斐波那契

一看就是規律

然而我選擇了暴力

其實完全可以打表去找規律。

然後就可以發現父親的順序也是斐波那契

就這

#includeusing std::cout; using std::endl;

#define int long long

#define debug cout<<"debug"/* void biao(int x)

if(x == 1)

int l = 1,r = 60;

while(l < r and l != r- 1)

biao(x - st[((l + r)>>1)] + 1);

}*/int ans;

/* void find(int x)

if(x == 2)

if(x == 1)

int l = 1,r = 60;

while(l < r and l != r- 1)

find(x - st[((l + r) >> 1)] + 1);

}*/void search(int x,int y)

if(x > y)

if(x == 1)

int l = 1,r = 60;

while(l < r and l != r - 1)

search(x - st[(l + r) >> 1] + 1,y);

} if(x < y)

if(y == 1)

int l = 1,r = 60;

while(l < r and l != r- 1)

search(x,y - st[(l + r) >> 1] + 1);

} }inline short main()

int query(int fa,int l,int r,int ql,int qr)

inline short main()

else

}return 0; }}

signed main()

還有lower_bound

#includeusing std::cout; using std::endl;

//#define int long long

#define debug cout<<"debug"《還沒改完,咕了

NOIP模擬賽考試總結

noip模擬賽考試總結 這兩天我們進行了以小奇為主題的noip模擬賽 考試總結 第一題看出是乙個dp,但是前面的決策對後面有影響,百思不得其解時想到後面決策對前面沒有影響,所以從後面開始dp,每步取max。第二題看了半天都不會,交了乙個暴力演算法,得了0分,因為我把字首和取模了,比如 1 2 3 4...

考試總結 noip模擬10

不小心有咕掉了一段時間 這次考試咕掉的分數也是太多了 然後就是這次暴力完全沒有打滿 遺憾啊遺憾 入陣曲 前面的題目背景故意引導我們去往矩陣快速冪的方向去想 然而半毛錢關係沒有 其實就是維護字首和 二維的然後就有顯然的 mathcal o n 4 的暴力。然而我這個 sb 在考試之前認為沒有開 lon...

考試總結 noip模擬8

又是乙個題的正解都沒有打出來的一天 但是自己獨創了 lca 的求法,然而如果去掉求 lca 的過程,就不會 tle 了。huge 然後就是對性質不是十分熟悉。t1 的尤拉路我是真的忘乾淨了,別說什麼性質了,提起來只還記得乙個一筆畫。然後還有就是單調性的誤判,然而拿了很多分,但是寫了乙個錯解。超級樹上...