• Python print to file
    17 November

    How to Print to File in Python?

    We use the print() function in python to print any text to standard output. In this article, we will see how we can use the print() function to directly print an output to a file. For this, we will first discuss the print() function and then we will see how we can print to file […]

  • Python absolute path
    17 November

    Get Absolute Path in Python

    We often use files to store the outputs of our programs in permanent storage. Generally, we work with relative paths of files in our programs. In this article, we will discuss two ways to get the absolute path to a file in python from its relative pathname. What is an absolute path to a file? […]

  • Python sort list of lists
    17 November

    Sort List of Lists in Python

    Several times we use 2-D lists or lists of lists in our programs to represent a table or matrix. When these tables need to be sorted according to some value, we need to sort the entire list of lists. In this article, we will discuss different approaches to sort a list of lists in python. […]

  • Remove nan from list in Python
    16 November

    Remove nan From List In Python?

    In python, nan is a special value used to represent missing values. In this article, we will discuss the properties of nan values. We will also look at different ways how we can remove nan values from list in python. What is nan in python? The nan values are special floating-point numbers defined in the […]

  • C++ wait seconds
    06 November

    How to wait for seconds in C++?

    There are multiple instances when we need to add delay to our program. For this, C++ provides us with very useful resources to add timed delay, sleep, etc into our program. For instance,  if we are waiting for a job to finish, we want to put something on hold, or we need something to be […]

  • C++ copy array
    06 November

    Copy Array in C++

    Arrays are used to store different objects of the same data type together at contiguous memory locations. We use arrays extensively in our programs and the array operations come in handy while performing several tasks. In this article, we will discuss how to copy array elements to another array in C++. We will also implement […]

  • Python String to function
    06 November

    Convert String to function call in Python

    Strings are one of the most used data structures when we process text data. We also use different functions in our program. But, have you ever tried to convert a string to a function given that a function with the same name has been defined in a different module or class? In this article, we […]

  • C++ read file into array
    06 November

    Read file into array in C++

    C++ is a powerful language that provides us with ways to read the data from files and write the data back to them. Files are a way of permanently storing the data on the disk so that data is not lost when the execution of the program ends. Often we need to retrieve data from […]

  • String to char Array in Python
    06 November

    Convert String to Char array in Python

    Strings are made up of characters. In python, we don’t have a character or char data type. All the characters are recognized as strings of length one. In this article, we will discuss different approaches to convert a string to a char array in python. We will also implement the programs to convert a string […]