A1go

43/55ページ

Leetcode # 205. Isomorphic Strings

https://leetcode.com/problems/isomorphic-strings/ Solution Time Complexity: O(s.length()) Space Complexity: O(s.length()) class Solution { public: bool isIsomorphic(string s, string t) { std::map<c ...

         続きを読む

[C++] std::set/map

  • 2022.11.28
  • C++

Hash table in C++ 初始化 std::set<template> s; std::set<template> s{…}; template arr = {…}; std::set<template> s(arr, arr + {length of arr}); — std::map<template_ke ...

         続きを読む

[C++11] std::accumulate

C++ 中的 sum() template<class InputIt, class T> (constexpr) T accumulate(InputIt first, InputIt last, T init(, BinaryOperation op)); frist, last range 為 [first, last) init initial value op 預設為 plu ...

         続きを読む
1 ... 43 ... 55
Bitnami