- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Found 34492 Articles for Programming
![Neetika Khandelwal](https://www.tutorialspoint.com/assets/profiles/507566/profile/60_4169811-1661487212.jpg)
269 Views
The task is to generate a string that consists of characters ‘a’ and ‘b’ which satisfies the condition mentioned below: str must have a length of A+B. The character 'a' must appear A times and the character 'b' must appear B times within the string. The sub−strings "aaa" and "bbb" should not appear in str. After generating the string, it should be printed. One possible solution is to first generate a string with all 'a's and 'b's, with 'a' occurring A times and 'b' occurring B times. Then, we can shuffle the string randomly until we find a ... Read More
![Neetika Khandelwal](https://www.tutorialspoint.com/assets/profiles/507566/profile/60_4169811-1661487212.jpg)
397 Views
FCFS CPU Scheduling (First Come, First Serve) is a fundamental CPU scheduling mechanism that executes programs in the order they are added to the ready queue. In other words, the first process to come will be carried out first, and so on. Since it uses a non−preemptive scheduling technique, a process that has been allocated to the CPU will keep running until it is finished or enters a waiting state. Scenario 1 Let's take a look at an example to understand FCFS CPU scheduling in more detail. Suppose we have three processes with the following arrival times and burst times: ... Read More
![Neetika Khandelwal](https://www.tutorialspoint.com/assets/profiles/507566/profile/60_4169811-1661487212.jpg)
175 Views
Operating system has a concept known as the optimal page size that is affected by a number of variables, such as the system architecture, the amount of physical memory at hand, and the workload of the running applications. Steps/ Approach The following steps can be used to find the ideal page size: Step 1: Establish the system's design:Different CPU designs support varied page sizes. For instance, x86 CPUs typically offer 4KB page sizes, whereas ARM CPUs support 4KB, 16KB, or 64KB page sizes. Step 2: Calculate the physical memory capacity:The ideal page size depends on the physical memory capacity. Larger ... Read More
![Neetika Khandelwal](https://www.tutorialspoint.com/assets/profiles/507566/profile/60_4169811-1661487212.jpg)
63 Views
The goal is to determine the minimum time required to complete the tasks in queue A based on the order of execution in queue B, given two queues A and B, each of size N, where: Pop this task and run it if the task identified at the head of queue B is also at the head of queue A. Pop the current task from queue A and push it at the end if the task discovered at the front of queue B is not also found at the front of queue A. One unit of time is ... Read More
![Neetika Khandelwal](https://www.tutorialspoint.com/assets/profiles/507566/profile/60_4169811-1661487212.jpg)
44 Views
Given are N processes and two N−sized arrays, arr1[] and arr2[]. A process's time in the critical section is recorded in arr1[], and it’s time to finish processing after leaving the critical part is recorded in arr2. The goal is to determine how long it will take for each process to finish processing (both inside and outside of the critical section) in any given order. Input Output Scenarios Assume we have 3 arrays as shown below Input N = 3, arr1[] = {1, 4, 3}, arr2[] = {2, 3, 1} Output 9 The first process, at ... Read More
![Neetika Khandelwal](https://www.tutorialspoint.com/assets/profiles/507566/profile/60_4169811-1661487212.jpg)
2K+ Views
A 3−tier application architecture is a modular client−server architecture that consists of a presentation tier, an application tier, and a data tier. The presentation tier is a graphical user interface (GUI) that interacts with the other two tiers; the data tier stores information; the application tier manages logic. A 3−tier architecture has pros in terms of better horizontal scalability, performance, and availability. When there are three layers, each component can be produced concurrently by a separate team of programmers using a different programming language than the developers of the other levels. The 3−tier paradigm makes it simpler for an organization ... Read More
![Gaurav Leekha](https://www.tutorialspoint.com/assets/profiles/529640/profile/60_198691-1681388259.png)
773 Views
The Python Uszipcode module is a powerful tool for working with United States zip codes in Python. This module provides a comprehensive set of functions and classes for working with zip codes, including searching for zip codes, identifying the location associated with a zip code, and calculating the distance between two zip codes. In this article, we will provide a detailed overview of the Python Uszipcode module and how it can be used to solve a variety of problems. What is the Python Uszipcode Module? The Python Uszipcode module is a Python library for working with United States zip codes. ... Read More
![Gaurav Leekha](https://www.tutorialspoint.com/assets/profiles/529640/profile/60_198691-1681388259.png)
995 Views
Sometimes we need data to be created or read in memory instead of actual files seen by the OS. This is where the Python StringIO module, an in-memory file-like object, comes into play. Read through this article to get a detailed explanation about the Python StringIO module. What is Python StringIO Module? Python StringIO module is an in-memory file-like object which can be used as both input and output to most of the functions expecting a standard file object. In other words, the file-like object acts like a regular file allowing most of the standard file I/O operations. One of ... Read More
![Gaurav Leekha](https://www.tutorialspoint.com/assets/profiles/529640/profile/60_198691-1681388259.png)
9K+ Views
When writing programs, it is often necessary to check multiple conditions in order to determine the appropriate course of action. In Python, the "if" statement is used to execute a block of code if a specific condition is true. However, in many cases, we need to check more than one condition at a time, which can be accomplished using logical operators, parentheses, and other tools. In this article, we will explore several techniques for checking multiple conditions within an "if" statement using Python. We will discuss the use of logical operators such as and, or, and not, as well as ... Read More
![Gaurav Leekha](https://www.tutorialspoint.com/assets/profiles/529640/profile/60_198691-1681388259.png)
879 Views
Convolutional Neural Networks (CNNs) are a type of neural network that is specifically designed to process data with a grid-like topology, such as an image. CNNs are composed of a number of convolutional and pooling layers, which are designed to extract features from the input data, and a fully connected layer, which is used to classify the features. The primary advantage of CNNs is that they are able to automatically learn the features that are most relevant for the task at hand, rather than having to rely on manual feature engineering. This makes them particularly well-suited for image classification tasks, ... Read More