Categories

## Modifying keyboard layout in ubuntu 20

My hp notebook has a german keyboard that seems to be a relabled version of a us keyboard. Because of this it lacks the <>| key that is usually located right of l-shift on german keyboards. This is obviously very annoying and so far I haven’t been able to find an alternative key kombination that […]

Categories

## Importance of halogens and nitrogen in degree of unsaturation

Why is oxygen(or other elements) isn’t present in the formulae for calculation of the value of Degree of Unsaturation as it usually more common than Nitrogen and Halogens. And whats so special about Nitrogen and Halogens to be in the formulae? Here is the formulae:$$DU=C+1-\frac{H+X-N}{2}$$ where $C,H,N,X$ are no. of carbon, hydrogen, nitrogen and halogen […]

Categories

## Python noob question: Polynomial multiplication question

Can someone help me out with my code, the only answer I get is [0,0] for all inputs-: def add_poly(a,b,n): p=[] for i in range((n*2)-2): p.append(0) for i in range(0,n-1): for j in range(0,n-1): p[i+j]=(a[i]*b[j]) return p n=2 a=[1,3] b=[0,2] print(add_poly(a,b,n))

Categories

## function which take string input and convert to list and string returns string but result is printed as list

This code must takes input like [‘isogram’, ‘ISo-gram’, ‘is og ram’, ‘ju-pyter’], converts and returns as [‘isogram’, ‘isogram’, ‘isogram’, ‘jupyter’] But it is printed as [‘i’, ‘s’, ‘o’, ‘g’, ‘r’, ‘a’, ‘m’] instead of ‘isogram’. why result = str(result) code doesn’t take effect? code: def preprocess(user_input): result = user_input.lower() result = [ch for ch in […]

Categories

## How to create a table using a list of lists

I’m trying to write a file where you have 2 rows, with the first row being numbers and the 2nd row being letters. As an example, I was trying to do this with the alphabet. list1=[‘A’,’B’,’C’,’D’,’E’,’F’,’G’,’H’,’I’,’J’,’K’,’L’,’M’,’N’,’O’,’P’,’Q’,’R’,’S’,’T’,’U’,’V’,’W’,’X’,’Y’,’Z’] list2=list1+list1 abcList = [[],[]] for i in range(len(list2)): i+=1 if i % 5 == 0: if i>=10: abcList[0].append(str(i) + […]

Categories

## How do i join 4 tables in sql

Hi there I am a beginner in SQL coding and recently got an assignment from my teacher that I am not too sure how to do. If someone could help me by explaining what to do and how to do it. The assignment is: As we have found the limitation of the 3 table system […]

Categories

## Recurrence Plot

I am trying to solve a recurrence plot of a time series but with this condition: the y-axis represents the relative time distances to the next recurrence points but not their absolute time. I found this code online and used it in the Lorenz System for X only. However, it doesnt satisfy the condition stated […]

Categories

## Creating a hierarchical dictionary with nested lists or dictionaries from 2 lists

I have 2 lists. The first has number denoting what part of the hierarchy that the value in the other list at the same index belongs. I am trying to get dynamic code that could theoretically go to any number of steps. The first 3 work correctly but when I had more steps to the […]

Categories

## Received 0 SUCCESS signal(s) out of 1. Unable to satisfy 100% MinSuccessfulInstancesPercent requirement

{ "AWSTemplateFormatVersion": "2010-09-09", "Parameters": { "VpcId": { "Type": "AWS::EC2::VPC::Id", "Description": "VpcId of your existing Virtual Private Cloud (VPC)", "ConstraintDescription": "must be the VPC Id of an existing Virtual Private Cloud." }, "Subnets": { "Type": "List<AWS::EC2::Subnet::Id>", "Description": "The list of SubnetIds in your Virtual Private Cloud (VPC)" }, "InstanceType": { "Description": "WebServer EC2 instance type", "Type": […]

Categories

## Received 0 SUCCESS signal(s) out of 1. Unable to satisfy 100% MinSuccessfulInstancesPercent requirement

{ "AWSTemplateFormatVersion": "2010-09-09", "Parameters": { "VpcId": { "Type": "AWS::EC2::VPC::Id", "Description": "VpcId of your existing Virtual Private Cloud (VPC)", "ConstraintDescription": "must be the VPC Id of an existing Virtual Private Cloud." }, "Subnets": { "Type": "List<AWS::EC2::Subnet::Id>", "Description": "The list of SubnetIds in your Virtual Private Cloud (VPC)" }, "InstanceType": { "Description": "WebServer EC2 instance type", "Type": […]