Program Listing for File Parentheses.h
↰ Return to documentation for file (ADS/string/Parentheses.h)
/*--------------------------------------------------------------------------*/
/*--------------------------- File Parentheses.h ---------------------------*/
/*--------------------------------------------------------------------------*/
/*--------------------------------------------------------------------------*/
/*----------------------------- DEFINITIONS --------------------------------*/
/*--------------------------------------------------------------------------*/
#ifndef __ADS_Parentheses
#define __ADS_Parentheses
/* self-identification: #endif constant */
/*--------------------------------------------------------------------------*/
/*------------------------------ INCLUDES ----------------------------------*/
/*--------------------------------------------------------------------------*/
#include "ADS/Contract.h"
#include <cstddef>
#include <string_view>
#include <utility>
#include <vector>
/*--------------------------------------------------------------------------*/
/*--------------------------- NAMESPACE ------------------------------------*/
/*--------------------------------------------------------------------------*/
namespace ADS {
[[nodiscard]] inline std::size_t longestBalancedSubsequence(
std::string_view s , char open = '(' , char close = ')' );
[[nodiscard]] inline std::pair< std::size_t , std::size_t >
longestBalancedSubstring( std::string_view s , char open = '(' ,
char close = ')' );
/*--------------------------------------------------------------------------*/
} // end( namespace ADS )
/*--------------------------------------------------------------------------*/
/*-------------------------- IMPLEMENTATION --------------------------------*/
/*--------------------------------------------------------------------------*/
#include "ADS/string/impl/Parentheses.tpp"
/*--------------------------------------------------------------------------*/
#endif /* Parentheses.h included */
/*--------------------------------------------------------------------------*/
/*------------------------- End File Parentheses.h -------------------------*/
/*--------------------------------------------------------------------------*/