leetcode/include/s0005_longest_palindromic_substring.hpp
2022-11-21 21:15:56 +08:00

37 lines
738 B
C++

#ifndef S0005_LONGEST_PALINDROMIC_SUBSTRING_HPP
#define S0005_LONGEST_PALINDROMIC_SUBSTRING_HPP
#include <string>
#include <algorithm>
#include <vector>
using namespace std;
class Solution1 {
public:
/**
* @brief Longest Palindromic Substring
*
* Given a string s, return the longest palindromic substring in s.
*
* @param s the given string
* @return longest palindromic substring
*/
string longestPalindrome(string s);
};
class Solution2 {
public:
/**
* @brief Longest Palindromic Substring
*
* Given a string s, return the longest palindromic substring in s.
*
* @param s the given string
* @return longest palindromic substring
*/
string longestPalindrome(string s);
};
#endif