Anagram solver in python Two strings are anagrams if they contain the same set of characters regardless of the order of individual characters such as “earth” and “heart”. Write python code to detect if two strings are anagrams. Python anagram solver code Here is the code in python. You may also check this solution in
Python repeated character in string Given a string of characters. Write python code to print the repeated characters Solution This is a typical dictionary based problem. Here is how to do that in Python. You may need to take a look at the following similar articles Character count in string java String repeated characters count
Second largest number python problem Given an array of numbers, write python code to find second largest number in array Code to find second largest number in list A C++ version can also be found here. Thanks for visiting. Please use the comments section for feedback.
Introduction Today, I am going to talk about memory mapping, a typical topic in operating systems design. I will provide a short summary of memory mapped files in an easy to follow manner. Before we start, I recommend that you get a basic idea about some relevant concepts such as multitasking and paging. Here are
Introduction I highly recommend that you check out the following article to get a quick idea about different terms used in operating systems with regard to concurrency, multitasking and threading. Back to our topic, In this short post, I am going to demonstrate the use of mutex in python. Let us get started. What on
Syntax The power function in Python can be easily computed by importing the math module as follows: You can alternatively use the ** syntax as follows: Modular Exponentiation The power function can also be used as: This is called modular exponentiation which is useful in some computer science applications especially public key cryptography, for example:
Introduction Any computer algorithm requires two control flow structures: iteration and selection. Our topic today is mainly about iteration using the Python for loop. The goal of this post is to achieve three objectives: Provide a beginner introduction to the for loop control structure Include example code snippets for copy and paste lovers Cover some
Some time ago, I applied for a software QA position and was given this assignment: Problem Given 2 input files with rows in the format: Write a python script to print: All accounts in the first file not in the second All accounts in the second file not in first All accounts in both files
I assume you have a Mac computer and web.py is already installed. I also assume openssl is installed. Follow the steps below to enable SSL on your web server. openssl genrsa -des3 -out server.key 1024 openssl req -new -key server.key -out server.csr openssl x509 -req -days 365 -in server.csr -signkey server.key -out server.crt In your
Introduction I was testing a client software which communicates with a server software using JSON format. The behavior of the client depends on the instructions specified in the server response. In order to test the client I had to modify the server response and try different scenarios. One way to change the server response is