Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
-
Economics & Finance
Articles on Trending Technologies
Technical articles with clear explanations and examples
Create A Responsive Coffee Website in HTML and CSS
This article will show you how to create a responsive coffee website using HTML and CSS. We'll design sections including a hero area, product showcase, and contact form that adapt beautifully to both desktop and mobile devices. Website Structure Our coffee website will include the following key components − A hero section with an eye-catching welcome message A product section showcasing coffee options with descriptions A contact section for user inquiries Responsive design that adapts to different screen sizes ...
Read Moreasksaveasfile() function in Python Tkinter
Tkinter is Python's built-in GUI toolkit. The asksaveasfile() function from tkinter.filedialog opens a save dialog that allows users to specify where to save a file and returns a file object for writing. Syntax asksaveasfile(mode='w', **options) Parameters Common parameters include: mode − File opening mode (default: 'w' for write) filetypes − List of file type tuples defaultextension − Default file extension initialdir − Initial directory to open title − Dialog window title Basic Example Here's how to create a simple save file dialog ? import tkinter as tk ...
Read MoreArithmetic operations in excel file using openpyxl in Python
Python can help us work with Excel files directly from the Python environment using the openpyxl module. We can refer to individual cells or ranges of cells in Excel and apply arithmetic operators on them. The results of these operations can be stored in specific cells whose location we define in our Python program. In the examples below, we perform various arithmetic operations using built-in Excel functions like SUM, AVERAGE, PRODUCT, and COUNT. We use the openpyxl module to create a workbook, store values in predefined cells, apply functions on those cells, and save the results to other cells ...
Read MoreHow to Create Netflix Login Page in HTML and CSS?
Creating a Netflix login page replica is an excellent way to practice web development skills and understand modern UI design principles. This tutorial will guide you through building a complete Netflix login page using HTML and CSS. Why Create a Netflix Login Page? Building a Netflix login page helps developers in several ways − Learn Layout Techniques: Practice creating responsive layouts and form design Portfolio Project: Showcase your CSS skills to potential employers UI/UX Understanding: Study how popular platforms design user interfaces ...
Read MorePython - Contiguous Boolean Range
Given a list of boolean values, we are interested to know the positions where contiguous ranges of the same boolean value start and end. This means finding where a sequence of True values begins and ends, and where a sequence of False values begins and ends. Using itertools We can use accumulate along with groupby from the itertools module. The groupby function groups consecutive identical values, and accumulate helps track the cumulative positions where each group ends ? Example from itertools import accumulate, groupby # Given list bool_values = [False, True, True, False, False] ...
Read MorePython - Column deletion from list of lists
In a list of lists, an element at the same index of each sublist represents a column-like structure. In this article we will see how to delete a column from a list of lists, which means deleting the element at the same index position from each sublist. Using pop() Method The pop() method removes and returns the element at a specific index. We can use list comprehension to apply pop() to each sublist ? # List of lists representing tabular data data = [[3, 9, 5, 1], [4, ...
Read MoreCreate A Glassmorphism Login Form in HTML and CSS
This article will show you how to design a glassmorphism login form using HTML and CSS. Glassmorphism is a popular UI design trend based on frosted glass effects, which make elements look translucent with a blurred background. What is Glassmorphism? Glassmorphism is a UI design style that gives an element a frosted-glass effect with the following characteristics − Blurred Background: Creates a glassy, frosted effect. Transparency: Allows part of the background to show through. Light Borders and Shadows: Adds depth and defines the shape. ...
Read MorePython - Check if given words appear together in a list of sentence
When working with lists of sentences, we often need to check if specific words appear together in any sentence. Python provides several approaches to solve this problem using loops, built-in functions, and functional programming techniques. Using List Comprehension with len() This approach uses list comprehension to find matching words and checks if all target words are present ? sentences = ['Eggs on Sunday', 'Fruits on Monday', 'Eggs and Fruits on Wednesday'] target_words = ['Eggs', 'Fruits'] print("Given list of sentences:") print(sentences) print("Given list of words:") print(target_words) result = [] for sentence in sentences: ...
Read MoreHow to create a circle with text in Tailwind CSS?
In this article, we will learn how to create a circular element with text inside using Tailwind CSS. Tailwind CSS is a utility-first CSS framework that allows for fast UI development with pre-built classes. Prerequisites: You need to have Tailwind CSS included in your project. You can add it via CDN by including this link in your HTML head section: Basic Circle with Text To create a circle with text, we use Tailwind's utility classes for width, height, background, border-radius, and flexbox centering − Circle ...
Read MorePython - Check if all elements in a list are identical
There may be occasions when a list contains all identical values. In this article we will see various ways to verify that all elements in a list are the same. Using all() Function We use the all() function to compare each element of the list with the first element. If each comparison returns True, then all elements are identical ? days_a = ['Sun', 'Sun', 'Mon'] result_a = all(x == days_a[0] for x in days_a) if result_a: print("In days_a all elements are same") else: print("In days_a all ...
Read More