instruction
stringlengths
71
95.1k
Displaying Some Multiples Write a program to calculate the multiples of a given number. Have the user enter a number, and then use a for loop to display all the multiples of that number from 1 to 12. It is not necessary to use a function. You must use a for loop. /* * Code by Clint <https://github.com/clieg> * * ...
The reactor possesses its own thread to wait for messages in an event loop. Users should be able to start or stop the reactor at any point. These two operations are not required to be thread-safe. Users should be able to asynchronously register or remove message handlers from the reactor. It is possible that users may...
I assigned the following contrived problem in a comparative programming languages course to give students practice with "streaming": Write function that returns the top ten players by points-per-game among the players that have been in 15 games or more. The input to your function will be an object, keyed by team, with...
I've only been learning Java for two weeks, and I had to complete this task as part of my course. My instructor could not give specific feedback as answer file is already provided, the code works but I am just wondering what some of you might think of my code if it can be refined. It's a basic pizza ordering program. T...
Here is the solution-> //Write a program to check the number whether it is palindrome or not #include <stdio.h> int main(void){ //Put variables for the further proceed int number, quotient=1, remainder,i=0; //To declare a character array char text[100]; //To show the message to the user printf("Enter an integer numb...
Currently with a given Date and an Interval in Day, I can calculate all of the appointment in the future. for example if you are supposed to have an appointment each 30 day starting '2020-09-24', all the future appointments would be calculated like this. --Source Table Creation DROP TABLE IF EXISTS #DimDate CREATE TAB...
Using Excel, I have one sheet ("db") with data extracted from MES. I have to analyze this data and I need: Articolo, Fase, Tipo Confezione, TURNO, Macchina, avg and median. I searched everywhere how to get the median with SQL, but I found only how to get median for one item alone. Then I wrote this code, and I loop eac...
So I made an XML database for my music player where I store songs data (title,artist,album,genre,year) the code for generating the database is working but slow as heck, the code works as following diagram. |Aritsts Database >|Aritst ->(Name...
this is my first time on StackExchange. I am new to writing code. This is a singly-linked list I made in Java using generics with no sentinel nodes (i.e. no empty head and tail nodes). Looking for feedback on how to be more efficient, clean, and generally improve my code writing to include best practices. Each method...
I am trying to solve the open kattis problem '10 kinds of people' (https://open.kattis.com/problems/10kindsofpeople) using a best-first search algorithm and c++. 10 Kinds of People The world is made up of 10 kinds of people, those who understand binary and those who do not. These different kinds of people do not alway...
Often before the lecture starts, and occasionally in the break I like to display a timer with a countdown until the lectures starts/ resumes while playing some lofi-hip hop in the background. While the university students seems to enjoy this, I am ashamed of the code running the timer. So my lecture schedules is as fol...
I have coded a tool to produce precise timing events in Java. You set a value in BPM, and you receive events in your listener at the most precise timing it possibly can be with Java. It is basic. A thread, a loop, read the bpm value, invokes the listener (lambda), compute the time to sleep to match the bpm requested, a...
Im new to Python and Scrapy and Im trying to write a code that would find if a website contains a specific word in it. I need to scrapy many websites with different layouts so the search is a general one. I would appreciate if you could comment do you see a more efficient way on how to perform this task. Here is my sol...
I was inspired by a previous post here that also wrote a pizza ordering application. This is the attempt I have made using OOP in mind as I thought that would be just the way to go. Here is Pizza.java import java.util.ArrayList; public class Pizza { private String size; private ArrayList<String> toppings; ...
I have the following HTML + JavaScript code: <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css" integrity="sha384-JcKb8q3iqJ61gNV9KGb8thSsNjpSL0n8PARn9HuZOnIxN0hoP+VmmDGMN5t9UJ0Z" crossorigin="anonymous"> <div class="container mt-4"> <!-- action="/reports_send/...
I would like to create a table where each column header contains a column name and a sort symbol. To do this, I'm using bootstrap. You can see my code below: .glyphicon-menu-down, .glyphicon-menu-up { display: block!important; font-size: 9px; } th { background-color: #0C69E8; } th { color: white; } th .ali...
In the past I had followed the Ray Tracing in a Weekend books using C++ because that was what the book used. However, recently I started thinking about how hard it would be to implement using C and whether I could do it. As a result I set a goal for implementing it using only C and I was able to mostly accomplish that,...
I have the following function that causes a significant visual jittering and lag in my access database - This is a treeview selection based on data in a table (tblDATA) with the fields: Object | Attribute | Property | Value I have tried echo and me.painting but figured my actual for loops need to be looked at for optim...
I've rewritten a piece of Javascript in Python 3.7 that decompresses a file compressed in a specific format. The project that I got this from is available here. The code I've come up with is as close an analog as I could interpret (I'm not the best at Javascript). def decompress_lz2(data): global loop_count lb_...
I created a TCP Server and Client and I really would like to know if its any good in regards of performance and code quality / safety. I hightlight the server and client class here. If you need more insight in the Helper classes I could share them as well. One thing I know is creating threads for each client is not rea...
This is a second shot at creating a Martingale betting simulator. The original code needed such heavy refactoring that I just started from scratch. Script simulates the Martingale betting strategy of betting a fixed amount until a loss occurs, at which point the bet is doubled to make up for the loss. This continues un...
I created a pretty straight forward snakes and ladders implementation in Java just for the heck of it. The program can be summed up as- Object of Board contains an array of Type Tile to represent the actual board. Object of type Tile contains an Enum data member to identify if its a regular tile or a snake/ ladder. A...
As part of my study, I decided to do this task from frontendmentor site. It's a short html code but I would like to learn good practices from the beginning. The problem I had encountered: Adding names to classes to make them readable What should I pay attention to when making the page accessibility In the code below ...
I have a piece of code that takes a dictionary as input and validates it based on the following rules: The dictionary has a key named items and its value must be a list Now, the list from point 1 must be a nested list with the length of each list should be 2 The first element ([0]) of every nested list must be of type...
I want to search for positions inside a range of integers. How to improve the code in terms of efficiency, since both my search list and the ranges are very big: #Range list with ids range_lst = [(121000, 122000, 'foo'), (123456, 124557, 'bar'), (156789, 163659, 'egg')] # Positions which we want to scan pos = [123456, ...
I wrote a simple, 2-player Pong game for a Udacity Nanodegree in C++. The program has the following class structure (relatively new to UML so any tips on here would be very much welcome too): Towards the end of the project, as I needed to add more features, my Game class started to do many many things (collision dete...
So I created a thread server that creates threads and associates them with a handle so that you can keep specific threads for specific tasks e.g. run all graphics rendering on thread 0, run physics stepping on thread 1 and use thread 2 for downloading a file of the internet etc. Personally I've found it useful in a pro...
The following code is a Node-based Netlify plugin to generate Content-Security-Policy rules based on inline styles and scripts. Inputs buildDir - a string for setting the build directory. exclude - an array of file paths to exclude from processing. (defaults []) policies - an object of policies in camel case, for exam...
To get the book list from https://www.java67.com/2015/09/top-10-algorithm-books-every-programmer-read-learn.html , I am using the following code in the console of the firefox DevTools: var select = document.querySelectorAll("div.post-body.entry-content div h3 b"); for (i = 0; i < select.length; ++i) { try { va...
The method works, but I would like to know if there is any way to make it more readable, optimized? I have user data (i want to import/update it). Accounts is finded by user data. User order data is entered into the system. userData.Id - user Id; userData.OrderNumber - user order number. The "UpdateAccount" method bel...
I've created a Node.js package that retrieves data from Icinga (a monitoring platform), formats it and passes it off to a class that generates some HTML and then sends it all out as an email. The email, in its simplest form, looks something like this: I come from a Ruby/Python background and this is the first time I'v...
I made a very primitive Tic-Tac-Toe using Python and I would like a grade on how well I coded the game. What code was there that could've been simpler or more efficient? And any advice you can give me? board = ['-','-','-','-','-','-','-','-','-'] request = None currentLetter = 'X' win = False def displayBoard(): ...
I use an online, simplified notebook. I'm able to add notes, delete notes, and edit existing notes. I find the code to be pretty unattractive and is heavily repeated. When I built this, I borrowed code from many sources (I was still learning web programming) and I had a hard time consolidating them. const pushToURL = (...
Motivated by yet another floating point question on stackoverflow, I decided to print a float value \$x\in[0,1)\$, i.e., the fractional part of a float (I might try printing whole floats later). But not the rounded value like print(x) does but the exact represented value. And only using basic operations: def print_floa...
So I was recently asked to complete the following challenge for an interview: Programming Problem Provide a production ready solution that accepts a new user name, validates a single string input as the password, and stores it locally. The solution should be written in C#/Xamarin with native UI (Android or iOS, your c...
This program is my attempt at solving the below problem: We have a function which is going to be called by multiple threads. The problem is to find a way to limit the number of times this function is executed per second given that we don't have a control over: a) The number of threads calling this function. b) The numb...
Im curious if my approach is correct in this case: I would like to get two DateTimes from a public property, but one of the dates i want them only if a user has purchase a feature or if he has not activate a switch, otherwise i want to get the same DateTime twice. More specifically, the way im getting the values now is...
I have the following query which retrieve all those who have ordered a book_id n°10 and but never ordered the book with id n°1. http://sqlfiddle.com/#!9/1bb9e8/44 |user_id | book_id | | 1 | 1 | | 1 | 2 | | 1 | 3 | | 2 | 1 | | 2 | 10| | 2 | 9 | | 3 | 5 | | 3 | 10| | 4 | 6 | | 4 | 7 | | 4 | 10| | 8 | 8 | select u.user_i...
I sometimes need to merge some big PDF files. Looking around I decided to use PyPDF2. All files are in the same directory as the script. The code works as intended and was tested with 5 small PDF files. I found many variations and decided to write this one myself: import glob from PyPDF2 import PdfFileMerger files = ...
I have a .NET application with a .config file that has content like this: <appSettings> <add key="SmtpConfiguration" value="Db" /> </appSettings> Inside the application's code I define an ISmtpConfiguration interface and several different implementations. DbSmtpConfiguration gets configuration data from a database...
If below piece of code has to be restructured to use but one single if-elif block, which is better? 1. or 2.? A = int(input("Enter an integer(1~30): ")) if A % 6 == 0: print("A is even") print("A is even and a multiple of 6 (6, 12, 18, 24, 30).") elif A % 10 == 0: print("A is even") print("A is e...
I've made a very basic wrapper over a String that offers mutability in place (context: mono/XNA, budget is about 11ms per frame, 0B (ZERO, NIL, НОЛЬ, NADA) allocations hard requirement). Before that I've used a wrapper over StringBuilder that essentially would do the same - get raw value of the string it operates on. p...
I have to register different callback functions to a scheduler. The callback signature defines a void * parameter. Some callbacks don't use a parameter. This works, but is it clean? I expected at least an incompatible pointer type warning for the missing cast on the parameterless call which I actually get when using a ...
I have piece of code where I draw output from model pixel by pixel: fun draw( canvas: Canvas) { val rotated = sensorOrientation % 180 == 90 var rotatedW = frameWidth; var rotatedH = frameHeight; if(rotated) { rotatedW = frameHeight rotatedH = frameWidth ...
I have many html files saved to my computer.they have same tags like this: Rpi-Cam-Web-Interface- Page 2 - forum and the page number changes I want to rename file to page number I use this code: import re import os pattern=re.compile('<title>RPi Cam Web Interface - Page \d*') for i in os.listdir(): parser=open(i,'r...
I've implemented a setTimeout thread similar to the one in JavaScript (new to thread programming) In the example on this page I see use of an atomic variable i which I think it to make sure no race conditions occurs on 'i', but from what I've read I don't think there is an atomic multimap. From the code a race conditio...
Expected Input: Enter the number of rows: 5 Expected Output: A A B A A B C B A A B C D C B A A B C D E D C B A I have solved this problem in this way-> //Write a program to build a pyramid with uses of alphabets #include <stdio.h> int main(void){ //Put variables here int space,num_of_rows,p=1,t=0...
I made the following snippet. It finds unique keys based on their values. For all keys \$s\$ that are contained in another key \$D\$ with the same value, key \$s\$ is discarded and key \$D\$ is returned. newdict = {} for key1, value1 in mydict.items(): for key2, value2 in mydict.items(): if ((key1 in key2) and (...
I had given a coding test for a job which failed. It had two problems and one of them is shared in this question along with my solution and other I already posted at this link. Problem: Find duplicate transactions. Description: Usually, due to any technical mistake, a single transaction is recorded twice in the databas...
i have made this time convertor this is my first project i am new to c++ and programming can you tell me if there is any way to write this code to be more efficient or this is code is ok. thanks for answering. #include <iostream> using namespace std; int main() { long double value; int input ; int input2; ...
I have a function which from an array of days return the array of days with it's date like from array of ['Sun', 'Mon', 'Tue', 'Wed' ] my function returns the days from today if there are some past days i switch the date to next week so the array will become ['Wed 23', 'Sun 27', 'Mon 28', 'Tue 29' ] And here is how my...
so obviously this SIMPLE code checks if the number is prime or not. I need to make it more advanced, easier to use, fewer lines or any improvement. while True: lista = [] try: num = int(input("Enter the amount of numbers: ")) for i in range(0, num): value = int(input("Enter the numbe...
Write a function make_human_move(current_player, board), which does the following: Print out the player's shape (e.g. if the player shape is 'X', the function prints "X's move"). Asks the human player for his/her move. The message asked is "Enter row and column [0 - 2]: ". A move consists of two integer values separat...
I am creating a VueJS component of an audio player. I am having some difficulties in finding the ideal way to get the arrow keys and space bar to work. I have found a solution, however I think it is not the best, nor the most effective. I've added an event listener to the DOM in the component, but the problem is that I...
I have a list of objects of class NameOwnersBasedOnRule with properties Name, Rule and Owner: var nameOwnersBasedOnRule = new List<NameOwnersBasedOnRule> { new NameOwnersBasedOnRule { Name = "Name1", Rule = "Rule1", Owner = "Owner1"}, new NameOwnersBasedOnRule { Name = "Name1", Rule = "Rule2", Owner...
edit: here is a cleaned-up version incorporating most (but not all) feedback, thanks guys; https://gist.github.com/divinity76/79efd7b8c0d7849b956cd194659c98e5 edit2, 2021-07-16: found a bug (possible security vulnerability, even?), it will fail on echo -ne "-ne", that can fixed that by adding $i !== 0 && before strpos...
I have the following which works but was wondering if there's a better way. Better meaning more efficient and or more compact. The function checks a trie to see if the word is in the trie. typedef struct nodeWords { char * word; int index; struct nodeWords *left; struct nodeWords *right; } nodeWords;...
I have a list and I need to get certain elements out of it. The way I did it was to compare the second list to the first list and then append to a third list. Here is my code: l1 = ["0 = 0","1 = 1","2 = 2", "And", "Something", "Wicked", "This", "Way", "Comes", f"zero.0 = 0", f"one.0 = 1", f"two.0 = 2", ...
I'm a student working as a research assistant and wrote this script to automate density functional theory HPC tasks with SLURM. When a calculation is complete the script checks the contents of a log file for the total force, and if it's above the desired threshold it generates a new input file, file.in.new, with relaxe...
I have an abstract Badge class, every class extending this class should always correctly set the incoming name (string) and achievedAt (date) fields. There might be other classes that extend the Badge class, which will get passed different types of values in their constructor (see examples below), the most important th...
I'm posting two similar solutions for LeetCode's "All Nodes Distance K in Binary Tree". If you'd like to review, please do so. Thank you! Problem We are given a binary tree (with root node root), a target node, and an integer value K. Return a list of the values of all nodes that have a distance K from the target node...
Currently trying to learn to add in some validations, but only run 2nd validation after the 1st one is fully done and has no errors. Just want to hear reviews regarding my current logic in my data validation. 1st Validation checks for empty fields 2nd Validation (only to work after 1st validation is done) checks if va...
As is known, the .container- class in Bootstrap 4.x.x and 5-alpha has an bug in intermediate classes. To give a little more detail, The container class of Bootstrap 5 .container, .container-fluid, .container-sm, .container-md, .container-lg, .container-xl, .container-xxl { width: 100%; padding-right: 1rem; paddin...
Follow up to this question: 10 Kinds of People Open Kattis Problem Time Limit Exceeded C++ Solves the puzzle linked in that question. I use Dijkstra algorithm to find items. The only twist is that each time I do a search I save the boundary list of the search in a Zone. On a subsequent search if my current "Zone" bumps...
I wrote this code. But it works very slowly. I'm figuring out how many times I have to run the case generator to find numbers less than or equal to inv, in this case six. I count the number of attempts until a digit <= 6 is generated. I find inv equal to 1 and repeat the loop. Until inv is 0. I will keep trying to gene...
The following is the program 3.2.6. from the book Computer Science An Interdisciplinary Approach by Sedgewick & Wayne: // This data type is the basis for writing Java programs that manipulate complex numbers. public class Complex { private final double re; private final double im; public Complex(double...
I am very new to Python and I am trying to learn through personnal projects and today I needed to collect a lot of baksetball player names and decided this was a good time to learn and practice. The script is able to pull out all of the players names, height, nationality and DOB but I need to enter the link to the page...
I'm building a Mozilla Firefox extension to hide link's formatting and show them as regular text. It consists of a script that runs on web-pages (content.js) that's activated by clicking on the extension (handled with background.js). On activation, a CSS rule is injected to hide link's formatting. Activating it again w...
I created the following program which takes a molecular formula as an input, eg CH3COOH and returns the molar mass of the compound: #! /usr/bin/env python3 element_weights = { 'H': 1.00794, 'He': 4.002602, 'C': 12.011, 'O': 15.999, 'Ts': 294.0, 'Og': 294.0, } def tokenize(string): position ...
So I wrote a a RESTfull api for a mongodb with python3.7, fastapi and mongoengine and id love to get feedback on how I should make my code more readable, clean, and dry. basically there are 4 main routes : Route to get all objects from a collection. Route to get one object from a collection by a specific identifier (...
I'm currently going over Robert Sedgewick Algorithms book. Here I'm implementing a Symbol Table using a Linked List. The Sequential Search Symbol table is implemented in JavaScript. The book mentiones that this Abstract Data Structure is not a good solution when dealing with big amounts of data. I would like feedback o...
I'm new to socket programming and c++. I have a the following method that sends an array to server and receives sum of the array, I tried to make it async. std::future<void> AsyncClient::ReqSum(const std::vector<double>& numbers) { return std::async( std::launch::async, [&, numbers]() { ...
For an API I have defined a "Client" struct which contains all the fields the client has in the database. When a GET request is made with the client ID the whole struct(The struct contains about 60 fields of different types) is returned with all available data. The request can be customized with a querystring "fields" ...
Today I discovered that it is possible to dynamically load code at runtime via dlopen and dlsym (and similar utilities on Windows as well). So the obvious next step was to call the compiler through system to build a piece of code into a shared object, which is then loaded to obtain a function pointer. All wrapped in a ...
I'm trying to implment memory allocator guided by this tutorial. I used a mix of Next-fit search and Segregated-list search. There are multiple slabs of different sizes (a slab is contagious blocks of memory of the same size, plus a header). If a slab ran out of free blocks, it allocates a new slab of the same size and...
My program brute-forces a password. The password is a string composed of a key and a four digit numeric code. The key is known so we are basically brute-forcing between 0000 through to 9999 An example password is: UoMYTrfrBFHyQXmg6gzctqAwOmw1IohZ 4143 I updated that script I wrote to take advantage of multiprocessing i...
This is a follow-up to Bash script to automate dev environment setup. In that question I'd thrown together a (sloppy) shell script to automatically setup my development environment. One of the answers suggested using Ansible and after a bit of reading realized it would help me with some configuration of remote servers ...
The config file for my project takes many files and directories. It would be convenient if these files and directories could reference git repositories, zip archives, possibly over https. This function converts those URLs to paths on the disk, so the rest of the project still only deals with Paths on disk. Did I handle...
Ok, a struct would actually be most convenient, but it woudl be easier on teh system to have 2 seperate arrays rather than an array of structs. #define PAIR(Str) {(Str), sizeof(Str)-1} static const struct StrStruct { const char *Str; unsigned int Len; } Packed4 DefaultStr[] = { PAIR("Error"), PAIR("An u...
So I'm parsing an object using Typescript. I am pushing a value from within the object into an array of strings. Here's the code: if (data.InstanceStatuses != undefined) if (data.InstanceStatuses[0].InstanceId != undefined) instanceIds.push(data.InstanceStatuses[0].InstanceId as string) I f...
Problem Statement : Print the first non repeating character in a string. Example : In the string somecharsjustdon'tliketorepeat, m is the first non-repeating charecter. My attempt : New Code : Old one was not working as expected so I have updated the post. Old code can be found below new code public class FirstNonRep...
I am new to programming and need input on how I could've written something better. Not coding on daily basis. The task was to write a script in python, bash or anything. So I mixed python with bash commands using python module os.systems. Some friends recommended lists but I wanted the output to be similar as the examp...
I have this function that searches for stock moves that have the same product, and if it finds them then it searches for lots in those lines, and if it finds the same lots then UserError is raised. The thing is I think this method can be rewritten in a more elegant way. Maybe someone can help me with that. def check_fo...
I am quite new in django forms. I am woking on problem where in function name generate_outage_form passed two parameters name settings and segment Now I have to make function less verbose and more robust. def generate_outage_form(settings, segment=None): form = None     datacenters = settings.get('datacenters')    ...
So, I have been recently heavily focusing on Front-End, for data validation, showing errors etc. And a big thank you to CertainPerformance for many reviews hes done for me :) I have created a Report template using handlebars and a MySQL database to store the data, using Node JS to interact between the 2. I have now gai...
I'm making a function that adds a new object to an array and removes the oldest if it has reached a specific length. Click the button in the example below. All objects are drawn until its array reaches a length of 5 when the oldest is removed. Is there a better, more processor and memory efficient way to do this instea...
tl;dr: How could you rewrite the buf_get and buf_set functions below to be most optimal? It took me a long time and a lot of head banging on the wall to get these buf_* functions to work, but they are not very elegant and I'm sure many of you can easily spot how to do these "more correctly". Basically, the uint8_* func...
So currently I have this function: function loadPath(chunkSize, dataSize, depth, index) { let path = [] let i = 0 while (i < depth) { path.unshift(index % chunkSize) index = Math.floor(index / chunkSize) i++ } return path } I would now like to pass in path as a variable from an object pool of sho...
I am learning Python. I have a scenario in my current project to benchmark the following code snippet; by using refactoring to increase the performance. Upon deployment my code will be used on a larger scale. I'm trying from my side and am also looking for suggestions/guidance from you all. Is there a way to make this ...
I'm writing spring app for storing and manipulating recipes. I wrote ShoppingList service which generates, based on UUIDs of recipes, shopping list. This is my current model for which i wrote tests and works as intended. Service uses another service called IngredientConverter which converts to response models. Now i wa...
I writing this code to leverage the advantages of Completable future. My doubt is call cancel() method after get() is correct approach? private void combineFilters(JobFilter jobFilter, CompletableFuture<List<String>> measureCompletableFuture, CompletableFuture<Li...
I have written a (relatively) generic function for interpolating values in power query (also useful for power bi and m code). I am looking for any improvements or input, but especially: speed handle more inputs correctly (more generic) documentation / readability of code (Input as table, xColumn as text, yColumn as t...
I'm a teen developer who just does this as a hobby, but I still care about good practice even if I don't fully understand it. Two of the most used phrases when sharing the code of my C# MySQL library is bundling and abstraction, First of all... do I need to reduce said phrases? If so, how can I do that? Among any other...
In order to continue improving my Python knowledge, I have implemented a naïve Bayes classifier as described in "An introduction to Information Retrieval". I would be very interested which parts could be improved, be it e.g. coding style or use of data structures. """Implementation of a naive Bayes classifier based on ...
Description I'm not sure if it Covid-19 but lately it is impossible to book a tennis court in my area on time. It's always full or maybe just don't check enough :) To beat the queue and get notified earlier, I started making a scraper to ensure I can book a court on time. But because of iframe hell and the lack (to my ...
I was practicing python on codewars.com with this question: Create a function that takes a positive integer and returns the next bigger number that can be formed by rearranging its digits. For example: 12 ==> 21 513 ==> 531 2017 ==> 2071 But when I attempted my solution it said it was not optimized enough Can someone s...
I am currently a Python beginner, who just finished a script simulating collisions between circles (balls) in 2 dimensions. I would appreciate comments on overall structure, variable names and really anything else. There are bug present, such as a ball occasionally slipping out of a corner, but the code is functional N...
Since I am working alone on this, I would like someone who would take a look and point out any mistakes or things I could have done better. My questions: How could I improve this big switch statement? Is there any obvious beginner flaws? The executeModeration is a method I call when a command is an moderation command...
Trying to improve my Python skills by creating a small text adventure. I have used lists to access certain information, but I am not sure if I am using them correctly. For instance, I have used a list to store weapons but wasn't sure of the syntax for accessing them in an if statement. Also, if there is any advice on h...
The idea is to take a sequence of sequences (of the same type) and use tuples of [iterator, current index, sequence size] to keep track of the current state, such that the cartesian_product object can return one sequence at a time. General questions: bugs? (would hope not!) code quality ok? anything i've missed? is th...