1.Problem: SNCKYEAR Solution list = [2010,2015,2016,2017,2019] T = int(input()) list_2 = [] for i in range(0,T): list_2.append(int(input())) for item in list_2: if item in list: print("HOSTED") else: print("NOT HOSTED") This Code is written in python 3.6 2.Problem: CHFAR Solution T = int(input()) result =[] while(T>0): data_input = input() list_1=list(data_input.split()) list_1 = [int(i) for i in list_1] K = list_1[1] data_input_2 = input() list_2 = list(data_input_2.split()) list_2 = [int(i) for i in list_2] count = 0 for item in list_2: if item!=1: count = count+1 if count...
Let's Begin Basic requirement to understand this program: 1. Matrix 2. Nested looping Code:------- #include<stdio.h> main() { int a[3][3],b[3][3]; int i,j,d[3][6]; printf("enter the elements of 1st matrix\n"); for(i=0;i<3;i++) { for(j=0;j<3;j++) { printf(" element [%d][%d]: ",i+1,j+1); scanf("%d",&a[i][j]); } } printf("enter the elements of 2nd matrix\n"); for(i=0;i<3;i++) { for(j=0;j<3;j++) { printf(" element [%d][%d]: ",i+1,j+1); scanf("%d",&b[i][j]); } } int k,l; for(k=0;k<3;k++) { for(l=0;l<3;l++) { for(i=0;i<3;i++) { for(j=0;j<3;j++) { if(a[k][l]==b[i][j]) { b[i][j]=0; } } } } } printf("vertical merge \n"); for(i=0;i<3;i++) {for(j=0;j<3;j++) { d[i][j]=a[i][j]; } } for(i=0;i<3;i++) {for(j=3;j<6;j++) { d[i][j]=b[i][j-3]; } }...