hello, whats wrong with my code? its giving an error as “runtime error (SIGILL)”.
#include
#include
#include
using namespace std;
int main() {
int t,i,a[200],j;
string s;
vector v1;
scanf("&d",&t);
while(scanf("%c",s))
{
v1.push_back(s);
}
vector<vector > v2(t,v1);
for(i=0;i<v2.size();i++)
{
for(j=0;j<v2[i].size();j++)
{
a[j]=v2[i].size()/2;
}
}
for(i=0;i<v2.size();i++)
{
for(j=0;j<a[i];j=+2)
{
printf("%c",v2[i][j]);
}
}
printf("\n");
return 0;
}