国产精品天干天干,亚洲毛片在线,日韩gay小鲜肉啪啪18禁,女同Gay自慰喷水

歡迎光臨散文網(wǎng) 會(huì)員登陸 & 注冊(cè)

C++制作brain fuck 編譯器(最終版)

2022-02-20 12:09 作者:夏夜wandpace  | 我要投稿

其實(shí)這個(gè)版本也沒(méi)更新啥,就是做了漢化,還有更新了一下界面,時(shí)候就基本沒(méi)更新什么了。

建議使用DEV-C++ 5.11制作,至于為什么,因?yàn)槲揖褪怯眠@個(gè)做的,其他的版本喝其他的編譯器會(huì)不會(huì)出問(wèn)題我就不知道了。有問(wèn)題可以問(wèn)我。

下面是完整代碼:

//================================================================

//? Name? ? ? ? ? ? ? ? ? ?:Brain_NTF.cpp

//? Author? ? ? ? ? ? ? ? ?:

//? Version? ? ? ? ? ? ? ? :SE2022

//? Copyright? ? ? ? ? ? ? :

//================================================================

//導(dǎo)入頭文件?

#define sspeed ios_base::sync_with_stdio(0);cin.tie(0)? ? ? ? ?

#include <algorithm>

#include <set>

#define maxn 100001

#define eps 1e-9

#include <iostream>

#include <cstdio>

#include <vector>

#include <sstream>

#include <queue>

#include <typeinfo>

#include <fstream>

#include <map>

#include <windows.h>

#include <cmath>

#include <cstring>

#include <ctime>

typedef long long ll;

using namespace std;

const int inf=0x7fffffff;

string s;

vector<char> a;

int kiss;

int i;

void dealk()

{

? ? void deal(char c);

? ? int start=i;

? ? while(1)

? ? {

? ? ? ? i++;

? ? ? ? if(s[i]==']')

? ? ? ? {

? ? ? ? ? ? if(a[kiss]==0)

? ? ? ? ? ? {

? ? ? ? ? ? ? ? break;

? ? ? ? ? ? }

? ? ? ? ? ? else

? ? ? ? ? ? {

? ? ? ? ? ? ? ? i=start;

? ? ? ? ? ? ? ? continue;

? ? ? ? ? ? }

? ? ? ? }

? ? ? ? deal(s[i]);

? ? }

}

void deal(char c)

{

? ? if(c=='+')

? ? ? ? a[kiss]++;

? ? if(c=='-')

? ? ? ? a[kiss]--;

? ? if(c=='>')

? ? {

? ? ? ? kiss++;

? ? ? ? if(kiss>=a.size())

? ? ? ? ? ? a.push_back(0);

? ? }

? ? if(c=='<')

? ? {

? ? ? ? kiss--;

? ? ? ? if(kiss<0)

? ? ? ? {

? ? ? ? ? ? a.insert(a.begin(),i);

? ? ? ? ? ? kiss=0;

? ? ? ? }

? ? }

? ? if(c=='.')

? ? {

? ? ? ? int m=a[kiss];

? ? ? ? printf("%c",m);

? ? }

?

? ? if(c==',')

? ? {

? ? ? ? char k;

? ? ? ? scanf("%c",&k);

? ? ? ? s[kiss]=k;

? ? }

? ? if(c=='[')

? ? {

? ? ? ? dealk();

? ? }

}

?

int main()

{

? ? SetConsoleTitle("Brain_NTF SE_2022_13a");

? ? cout<<"? ? ? ? ? ? ? ? ?Brain_NTF SE_2022_13c? ? ? ? ? ? ? ? ? ?\n";

? ? cout<<"=======================關(guān)于此程序========================\n";

? ? cout<<"|? ? ? ? ? ? ? 此程序基于MSDOS技術(shù)所制作? ? ? ? ? ? ? ? ?|\n";

? ? cout<<"|? ? ? ? ? 此程序序列號(hào)::6N23Y-7850H-6045H? ? ? ? ? ? ? |\n";

? ? cout<<"|? ? ? ? ? ? ? ?Brain_NTF 2022-2023(R)? ? ? ? ? ? ? ? ? ?|\n";

? ? cout<<"|? ? ? ? ?嚴(yán)禁非法拷貝,未經(jīng)過(guò)許可不能私自轉(zhuǎn)載? ? ? ? ? ?|\n";

? ? system("color 06");

? ? cout<<"**********************請(qǐng)?jiān)谙路綄?xiě)代碼**********************\n";

? ? while(cin>>s)

? ? {

? ? ? ? a.clear();//每次開(kāi)始運(yùn)行都清空一次vector?

a.push_back(0);

? ? kiss=0;//使用全局變量kiss?

? ? ? ? for(i=0;i<s.size();i++)

? ? ? ? {

? ? ? ? ? ? deal(s[i]);

? ? ? ? }

? ? }

? ? return 0;

}

?


C++制作brain fuck 編譯器(最終版)的評(píng)論 (共 條)

分享到微博請(qǐng)遵守國(guó)家法律
开鲁县| 湘阴县| 周口市| 徐州市| 南投县| 原平市| 淮南市| 固始县| 天峨县| 砚山县| 武定县| 尉犁县| 滦南县| 商洛市| 彰化县| 铁岭市| 嘉义县| 鄂尔多斯市| 镇原县| 湟中县| 黄陵县| 工布江达县| 通江县| 北海市| 宁津县| 海门市| 盘锦市| 万盛区| 修武县| 穆棱市| 临夏市| 万宁市| 池州市| 河北省| 武夷山市| 扶风县| 泗水县| 石楼县| 乐安县| 探索| 七台河市|