Untitled
unknown
c_cpp
2 years ago
630 B
7
Indexable
#include <iostream>
#include <string>
#include <windows.h>
#include <shellapi.h>
int main() {
int a;
int b = 0;
const char* c[8];
c[0] = "https://www.youtube.com/watch?v=dQw4w9WgXcQ";
c[1] = "https://www.youtube.com/watch?v=mV5xJT7BnzE";
int len = MultiByteToWideChar(CP_ACP, 0, c[0], -1, NULL, 0);
wchar_t* wstr = new wchar_t[len];
for (int i = 0; i < 8; i++)
{
MultiByteToWideChar(CP_ACP, 0, c[0], -1, wstr, len);
}
for (int i = 0; i < 8; i++)
{
std::cin >> a;
switch (a)
{
case 1:
ShellExecute(0, 0, wstr, 0, 0, SW_SHOW);
break;
case 2:
break;
default:
return 0;
}
}
}Editor is loading...
Leave a Comment