diff --git a/2558/2558.cpp b/2558/2558.cpp index ae4f358..9d1a3b8 100644 --- a/2558/2558.cpp +++ b/2558/2558.cpp @@ -2,6 +2,7 @@ #include #include #include +#include void print(std::vector& gifts) { for (auto gift : gifts) @@ -16,7 +17,7 @@ namespace { std::sort(gifts.begin(), gifts.end()); for (int i = 0; i < k; ++i) { - auto value = std::sqrtl(gifts[gifts.size() - 1]); + auto value = std::sqrt(gifts[gifts.size() - 1]); if (value == 1) continue; auto it = std::upper_bound(gifts.begin(), gifts.end(), value); diff --git a/3341/3341.cpp b/3341/3341.cpp index f469375..2ae69d1 100644 --- a/3341/3341.cpp +++ b/3341/3341.cpp @@ -1,6 +1,8 @@ #include #include #include +#include +#include namespace { struct Coord { diff --git a/838/838-2.cpp b/838/838-2.cpp index 25d276f..ae45367 100644 --- a/838/838-2.cpp +++ b/838/838-2.cpp @@ -2,6 +2,7 @@ #include #include #include +#include namespace { diff --git a/CMakeLists.txt b/CMakeLists.txt index 124d1df..ca37c2e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.30) +cmake_minimum_required(VERSION 3.25) project(leetcode) set(CMAKE_CXX_STANDARD 20)