Я создаю игру в скрэббл, и мне нужно получить базовую оценку слов в словаре.
Я использовал make_tuple и сохранил ее в своем кортеже. Есть ли способ получить доступ к элементам кортежа, как если бы он был вектором?
#include
#include
#include
#include
void parseTextFile()
{
std::ifstream words_file("scrabble_words.txt"); //File containing the words in the dictionary (english) with words that do not exist
std::ofstream new_words_file("test.txt"); //File where only existing words will be saved
std::string word_input;
std::tuple tupleList;
unsigned int check_integrity;
int counter = 0;
while(words_file >> word_input)
{
check_integrity = 0;
for (unsigned int i = 0; i < word_input.length(); i++)
{
if((int)word_input >= 97 && (int)word_input
Подробнее здесь: https://stackoverflow.com/questions/583 ... of-a-tuple