Posts

Digital Marketing

Get all running EC2 instances in your AWS account

aws ec2 describe-instances --filters Name=instance-state-code,Values=16 --query "Reservations[*].Instances[*].InstanceId" --output text

Lombok is an annotation-based Java library that helps in reducing the boilerplate code

Project Lombok is a Java library that automatically plugs into your editor and builds tools, spicing up your Java To use Lombok annotations in the project we need to add the following Maven dependency: <!-- https://mvnrepository.com/artifact/org.projectlombok/lombok --> <dependency>     <groupId>org.projectlombok</groupId>     <artifactId>lombok</artifactId>     <version>1.18.32</version>     <scope>provided</scope> </dependency>

The 2024 top-ranked universities in Canada

According to CWUR, the 2024 top-ranked universities in Canada are: University of Toronto Global Rank: 24 McGill University Global Rank: 28 University of British Columbia Global Rank: 49 University of Alberta Global Rank: 77 University of Montreal Global Rank: 117 McMaster University Global Rank: 172 Western University Global Rank: 189 University of Calgary Global Rank: 192 University of Waterloo Global Rank: 204 University of Ottawa Global Rank: 213 University of Manitoba Global Rank: 283 Laval University Global Rank: 297 Queen's University Global Rank: 320 Dalhousie University Global Rank: 341 Simon Fraser University Global Rank: 354 University of Victoria Global Rank: 397 University of Saskatchewan Global Rank: 414 York University Global Rank: 433 University of Guelph Global Rank: 479 Carleton University Global Rank: 534 University of Sherbrooke Global Rank: 583 Concordia University Global Rank: 613 University of Québec at Montreal Global Rank: 634 Memorial University of Newfound

HTTP/2 offers several improvements over the earlier version, HTTP/1.1

Prioritization: Developers have detailed control over the order in which content loads. This maximizes page load speed across different browsers. Certain resources (render-blocking resources) no longer block the rest of the page from loading.

Python Testing Frameworks

Python offers several testing frameworks. Here are three common ones: unittest: A built-in framework inspired by Java’s JUnit. It provides test discovery, fixtures, and assertions. Pytest: A popular third-party framework known for its simplicity, powerful features, and concise syntax. Pytest automatically discovers and runs tests. doctest: A lightweight framework that extracts test cases from docstrings. It’s useful for testing examples in documentation

Running Python Scripts

To create and run Python scripts: Download Python (it’s free!). Create a script file with the extension .py. Add your Python code to the file. Open your terminal or command prompt. Type python followed by the path to your script file. Execute the script by pressing Enter

Python for Automation

Python is a popular programming language for task automation due to several factors: Simplicity and Intuitiveness: Python’s syntax is easy to read and comprehend, making it accessible even for beginners. Data Structures Support: Python offers various data structures (such as lists and dictionaries) and allows users to create custom data structures, facilitating data management. Extensive Libraries: Python comes with a vast set of libraries that enable automation across various domains, including machine learning and operating system management. Its large support network ensures answers to most automation questions are readily available online