⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 tennispredictor.cpp

📁 C人工智能游戏开发的一些实例源代码 C Game development in artificial intelligence source code of some examples
💻 CPP
字号:
//----------------------------------------------------------------------------------------------
// Sequential Prediction Demo: The positioning pattern
// 
// Author:  Fri Mommersteeg
// Date:    10-09-2001
// File:    TennisPredictor.cpp
//----------------------------------------------------------------------------------------------

//----------------------------------------------------------------------------------------------
// Include files
//----------------------------------------------------------------------------------------------

#include "stdafx.h"
#include "tennispredictor.h"

//----------------------------------------------------------------------------------------------
// GetWindowSize(): returns the size of the window
//----------------------------------------------------------------------------------------------

int CTennisPredictor::GetWindowSize() {
	return m_Window.GetSize();
}

//----------------------------------------------------------------------------------------------
// GetWindowEntry(): returns an entry in the window
//----------------------------------------------------------------------------------------------

int CTennisPredictor::GetWindowEntry(int i) {
	return m_Window[i].Element;
}

//----------------------------------------------------------------------------------------------
// GetMaxMatchSize(): returns the size of the longest substring that matches the tail of the
//					  window.
//----------------------------------------------------------------------------------------------

int CTennisPredictor::GetMaxMatchSize() {
	return m_nMaxSize;
}

//----------------------------------------------------------------------------------------------
// GetMaxMatchPosition(): returns the position (defined by its last element) of the longest 
//						  substring that matches the tail of the window.	
//----------------------------------------------------------------------------------------------

int CTennisPredictor::GetMaxMatchPosition() {
	return m_nMaxPosition;
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -