teleren/devto huggingface dataset:
Easy steps to set up Nodejs for development
Tags: node, beginners, programming, webdev
Published: 2022-07-16 00:31:57

### What is Nodejs
Nodejs is a :
1. a run-time environment that allows JavaScript code to be executed outside of a browser
2. features an event-driven architecture that allows for asynchronous I/O (input/output) and is thus utilized in many real-time web applications, such as chat applications and game servers.
3. There are two primary use cases: server-side scripts and command-line utilities.
4. There is no need to master two languages to create full-stack applications because you can use javascript from the UI to the server you can read more [about Nodejs](https://nodejs.org/en/about)

#### How to install Nodejs
To run Javascript on a server you need to have Nodejs installed. To install Nodejs and installing Nodejs is an easy step 
>Install Nodejs versions with even numbers because those releases are more stable

#### Windows
1. Visit [Nodejs](https://nodejs.org/en)
2. Click on the recommended download button or select your binary installer, after downloading click on the .exe file to install on your PC
3. Run the installer
4. Sometimes you need to restart your PC. After that open your command prompt (press the win key + R and type cmd on the input box)
5. After opening the command prompt type `node --version` to get the version on Nodejs installed


#### macOs
1. Visit [Nodejs](https://nodejs.org/en)
2. Click on the “ macOS Installer ” option to download the .pkg installer. Make sure you download it to your desired location.

3. Run the installer
4. Installing from home brew `brew install node` after that run `node  --version`

#### Linux

1. Open your terminal and run `sudo apt install nodejs`
2. Installing on Arch Linux `pacman -S nodejs npm`
3. Run `nodejs --version`


What next to do after installing Nodejs? In my next article, I will be showing how to create a simple server using the Expressjs library
Hello, World!
Tags: programming, beginners
Published: 2022-07-16 00:18:00

This is my first blog so I thought I should start this blog by writing `Hello, World!` just like we do with the programming. 
> Hello, World!

There is no definitive answer to this question as it is unclear when the first "Hello, World!" program was written. However, it is generally believed that the first "Hello, World!" program was written by [Brian Kernighan](https://en.wikipedia.org/wiki/Brian_Kernighan) in 1972.

Hello, World! programs have been written in almost every programming language imaginable. As the first program that many people learn, it is generally simple and straightforward. However, some Hello, World! programs can be quite complex and creative.

One of the earliest Hello, World! programs were written by Tim Berners-Lee, the creator of the World Wide Web. His program simply displayed the text "Hello, world!" on a web page.

Hello, World! programs have been used to demonstrate the power of new programming languages, to test new hardware or software, and even to make political statements. In 2014, the European Organization for Nuclear Research (CERN) released a Hello, World! program that was used to discover the Higgs boson, one of the most important particles in the universe.

Below are some of the implementations of programming language to print `Hello, World!`
<img src="https://c.tenor.com/cX92mi1p-NYAAAAC/coding-anime.gif4" alt="alt text" title="Title" />

**C**
```
#include <stdio.h>
int main()
{
  printf("Hello, World!");
  return 0;
}
``` 

**CPP**
```
#include <iostream>
int main()
{
  std::cout << "Hello, World!";
  return 0;
}
``` 

**Javascript**

```
console.log("Hello, World!");
``` 

**Python**
```
print("Hello, World!")
``` 

**Java**
```
public class HelloWorld {
  public static void main(String[] args) {
    System.out.println("Hello, World!");
   }
}
``` 

**Julia**

```
println("Hello, World!")
``` 

**C#**

```
using System;

namespace HelloWorld
{
    class Program
    {
        static void Main(string[] args)
        {
            Console.WriteLine("Hello, World!");
        }
    }
}
``` 

**GoLang**

```
package main

import "fmt"

func main() {
	fmt.Println("Hello, World!")
}
``` 

**Verilog**

```
module HELLO_WORLD(); 
  initial begin
    $display("Hello World");
    $finish; 
  end
endmodule
``` 
Hello, World! programs will continue to be written as long as there are new programming languages to learn and new hardware to test. They will always be a part of the computer world, and will likely remain one of the most popular ways to learn a new programming language.

That's the end of this article! Hope you liked it!
What is the React Virtual DOM?
Published: 2022-07-16 00:12:58

The **React** Virtual **DOM** is a library that allows developers to create and modify HTML and XML in real time while the page is running. The **React** Virtual DOM makes it possible for developers to update parts of a web page without reloading the entire browser window. This means changes made to markup inside of an element will be automatically reflected in the output, without requiring user input or extra clicks.

Read also about : [Getter and setter in React js](https://professional-writer0.blogspot.com/2022/07/react-js-getter-and-setter-tutorial.html)

The **React** Virtual DOM is a library that helps developers build user interfaces using **React**. It helps to create a replica of the DOM trees that are used in React applications. This saves developers time and eliminates the need to write unnecessary code.

The **React Virtual DOM** works by tracking the changes that are made to the DOM trees. When a change is detected, the React Virtual DOM automatically updates the corresponding node in the replica DOM. This ensures that the user interface is always up to date.

The React Virtual DOM is important because it enables developers to write code that is shorter and more focused. It also improves the performance of React applications.

The React Virtual DOM is a valuable library that helps to improve the performance of React applications. It also helps to make user interface updates simpler and faster.
#JulyOT 16: IoT Device Selection List for Prototyping
Tags: julyot, iot, maker, prototype
Published: 2022-07-16 00:33:53

---
title: #JulyOT 16: IoT Device Selection List for Prototyping
published: true
date: 2022-07-16 00:00:00 UTC
tags: julyot,iot,maker,prototype
canonical_url: https://JulyOT.dev/blog/16-iot-devices-for-prototyping
series: JulyOT 2022
cover_image: https://JulyOT.dev/assets/images/JulyOT-banner-16-iot-devices-for-prototyping-b8b930a1ea1f3ab3c626ec1accb8c796.png
---

_Today we share a list of IoT devices for prototyping your IoT application._

## IoT devices for prototyping[​](#iot-devices-for-prototyping "Direct link to heading")

The MakeIt team at Microsoft is there to support the maker community, helping you to get your makes and prototypes built quicker with the best in class tools you need.

One way we are helping makers is sharing a list of IoT devices for prototyping your IoT application. This list aims to give partners a starting point with IoT hardware to build prototypes and proof-of-concepts quickly and easily.

This list is in an Excel spreadsheet, and is available from the [Microsoft Maker Community Resources repo on GitHub](https://github.com/microsoft/MakerCommunityResources).

<form action="https://github.com/microsoft/MakerCommunityResources/raw/main/IoT/IoT%20Device%20Selection%20List%20for%20Prototyping.xlsx" target="_blank"><input type="submit" value="Download the list from GitHub"></form>
How to Install and Configure MySQL Database
Tags: database, mysql, workbench, beginners
Published: 2022-07-15 23:59:05

As a Data Analyst, you will need to demonstrate SQL your ability to work with databases to recruiters. In fact, several job interviewers have SQL questions and assessment in them.

One of the friendly way of starting is by Installing the database server on your PC.
In this video, I walk you through how to install and configure MySQL Database on your windows PC.
Download PDF Files Using Python
Tags: python, tutorial, programming, productivity
Published: 2022-07-15 23:33:00

This article discusses how to download a PDF using Python's `requests` library.

## Approach
1. Import `requests`library
2. Request the URL and get the `response` object.
3. Get the PDF file using the `response` object, and return `True`.
4. If the PDF cannot be downloaded, return `False`

## Implementation

The following program downloads a PDF files from the provided URL.

```python
#!/usr/bin/env python3
import os
import requests


def download_pdf_file(url: str) -> bool:
    """Download PDF from given URL to local directory.

    :param url: The url of the PDF file to be downloaded
    :return: True if PDF file was successfully downloaded, otherwise False.
    """

    # Request URL and get response object
    response = requests.get(url, stream=True)

    # isolate PDF filename from URL
    pdf_file_name = os.path.basename(url)
    if response.status_code == 200:
        # Save in current working directory
        filepath = os.path.join(os.getcwd(), pdf_file_name)
        with open(filepath, 'wb') as pdf_object:
            pdf_object.write(response.content)
            print(f'{pdf_file_name} was successfully saved!')
            return True
    else:
        print(f'Uh oh! Could not download {pdf_file_name},')
        print(f'HTTP response status code: {response.status_code}')
        return False


if __name__ == '__main__':
    # URL from which pdfs to be downloaded
    URL = 'https://raw.githubusercontent.com/seraph776/DevCommunity/main/PDFDownloader/assests/the_raven.pdf'
    download_pdf_file(URL)

```
### Output

```cmd
the_raven.pdf was successfully saved!
```

## Conclusion 

After reading this article you should now be able to download a PDF using Python's `requests`library.  Remember that some website might more difficult than others to get data from. If you are unable to download the PDF file, analyze the [HTTP response status codes](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status) to help determine what wrong. Please leave a comment if you found this article helpful.

---

Code available at [GitHub](https://github.com/seraph776/DevCommunity/tree/main/PDFDownloader)
Day 97: Sharing is caring and it feels good
Published: 2022-07-15 23:30:52

Hi!
I think one of the good things about knowledge is being able to share with others and that feeling you get when you help someone with their blocker and you know they are genuinely grateful. whenever someone comes to me for help on something that may even seem easier to me I always get reminded of the time (not so long age) when I was in the same shoes and the way I too got help from people others which made me realize we are all a big family growing and learning from each other. Today I wanted to sleep early with the weekend and everything but I took some time to help someone with their blockers. I may have missed some hours of sleep (or maybe stupid social media scroll) but I did what mattered and and It was so good!

Tomorrow will focus on a few designs retouch and maybe take a rest 
Day 97 by the way Let's gooo!
Signing off...
AWS Community Builders Application
Tags: aws, awscommunitybuilders, community, opportunity
Published: 2022-07-15 23:29:57

Are you someone or know someone who is a technical professional, passionately sharing about AWS tools and technologies with the wider developer community / peer groups through blogs, videos, Open Source projects & more?

Here is an opportunity to be a part of a global network of passionate AWS enthusiasts / thought leaders and to level up your skills.

✨AWS Community Builders✨ offers technical resources, education, & networking opportunities to AWS technical enthusiasts who are passionate about sharing knowledge & connecting with the technical community.


How you can become builder:
🎥 YouTube videos
💡 Professional blog posts
🎤 Podcasts attendance or creation
🗣 Meetups / UserGroups organisation
👩‍👩‍👧‍👦 Conference speaking
🔧 Authoring tools
📘 Authoring Books


🔗 Apply here: go.aws/3yuOCDF
☁️ Application close July 17th

#aws #awscloud #awswscommunity #awscommunitybuilders #amazonwebservices #cloudengineer #awscloud #awscertification #community #mentorship #cloud #sharingknowledge #developercommunity #devopscommunity #opportunities2022 #onlinecommunities
Address validation
Published: 2022-07-15 23:25:14

I was researching to use Amazon location service and I wanted to validate addresses. 

I have limited knowledge on Node.js and JavaScript. May someone convert the python code to JavaScript or Node.js:

Geocoding with Amazon Location Service
Here is an example of calling the Amazon Location Service Places API using the AWS SDK for Python (Boto3). This uses the search_place_index_for_text method:

python code below:

**Response = location.search_place_index_for_text(
	IndexName = ‘explore.place’ 
	Text = “Boston, MA”)
location_response = Reponse[“Results”]
print(location_response)**


Thank you for the help.
Data Integration Using Machine Learning, A Brief Walkthrough
Tags: dataset, deduplication, aws, findmatches
Published: 2022-07-15 23:19:07

This is a step by step walkthrough image guide for the "Integrate and deduplicate datasets using AWS Lake Formation FindMatches" originally posted by Sergei Dobroshinsky and Tim Jones on 08 AUG 2019


[](https://aws.amazon.com/blogs/big-data/integrate-and-deduplicate-datasets-using-aws-lake-formation-findmatches/)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/s4ybdbc1gyl6gysqzvet.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/p2tl6lx4v8cc9pi7rhaa.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/d5659wytle6edg4awguc.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2ti9ehy89fv3ogghy0ek.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0b4o7g3g6ohcum5lo0th.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/17camc30eqq6xrb6qkfx.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/rj93iju8tcvwwdglnz72.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4xps28celayr5vzkrezq.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/vq5gd7k6fpx5zovtf5uy.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/j62jz7c8crciuvl6bwk8.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/l72bin8yd2udb0kh7la8.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/w29y3bmm07nexya2bj91.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/hg130qebbigha7yogusl.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/bsk8c5vehyqlqgcd12yh.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/t21wuuvs4x037e2uxw2n.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/tsg5eryezofmcn0kfkqr.jpg)
Heapify a list into Max Heap
Tags: tutorial, programming, python
Published: 2022-07-15 22:16:00

If you don't know - Heap is one of the awesome data structures you should learn. Why?
- Heap can find min/max in `O(1)`
- Insertion/Deletion can be done in `O(logn)` whereas in arrays insertion take `O(n)`
- If you learn this data structure, you will be able to grasp heap-sort, priority queue and heapifying an array concept.

If you are interested to learn more about Heaps, here are some resources to get you started:
- [Wikipedia](https://en.wikipedia.org/wiki/Heap_(data_structure))
- [Simplest video explanation](https://www.youtube.com/watch?v=HqPJF2L5h9U)

So how you can convert an array to a Heap.
```python
list = [20, 5, 30, 10, 15, 45]

def getChildren(pIndex, list):
    leftIndex = pIndex * 2 + 1
    rightIndex = pIndex * 2 + 2
    
    left = -1
    if leftIndex < len(list):
        left = list[leftIndex]
    
    right = -1
    if rightIndex < len(list):
        right = list[rightIndex]
    
    return left, right
    
def heapify(list):
    
    for i in range(len(list)-1, -1, -1):
        p = list[i]
        left, right = getChildren(i, list)
        
        bigChild = max(left, right)
        
        bigChildIndex = 2 * i + 1
        if right == max(left, right):
            bigChildIndex = 2 * i + 2
        
        j = i
        while p < bigChild and bigChildIndex < len(list) and j < len(list):
            list[j] = bigChild
            list[bigChildIndex] = p
            
            j = bigChildIndex
            left, right = getChildren(j, list)
            bigChild = max(left, right)
            bigChildIndex = 2 * j + 1
    
    return list

print(heapify(list))
```

[Photo by Pixabay](https://www.pexels.com/photo/abstract-business-code-coder-270348/)
SQL Data Cleaning Project Showcase
Published: 2022-07-15 22:40:23

It’s been estimated that almost 60% of data analyst and scientist time is spent on data cleaning for a given project so, this is a very relevant skill to showcase to your employer.

Unlike Data Visualization Project, it can be difficult to prove your SQL skill to potential employers or recruiters.

Your ability to carry out Data Cleaning with SQL can be a big add-on to your skill.

In this article, I review the work done by Jennifer Francis-Nkpornwi, one of the data community members. This project is really awesome and I would like you to add it to your portfolio too by doing something similar.

{% embed https://youtu.be/lN7DmWBkpp0 %}

Follow me for more content on Tech, Data, and Lifestyle
VSCode Settings You Should Use
Tags: vscode, settings, jannatinnaim
Published: 2022-07-15 22:21:16

Get started with the base settings for using VSCode. It seems like a simple text editor at first and all the noise around "extensions" really drive you away from just how much the editor itself is capable of. Here are some settings to help you use VSCode more effectively in your day to day workflow.

## Text Editor

- Bracket Pair Colorization - On
- Guides
  - Bracket Pairs - On
  - Bracket Pairs Horizontal - On
  - Highlight Active Bracket Pair - On
- Line Height - 1.25
- Linked Editing
- Rulers - 80, 90, 100, 120
- Tab Size - 2

### Cursor

- Cursor Blinking - Solid

### Font

- Font Family - JetBrainsMono Nerd Font, monospace
- Font Ligatures - On
- Font Size - 16

### Formatting

- Format On Paste - On
- Format On Save - On
- Format On Type - On

### Minimap

- Enabled - Off

### Suggestions

- Inline Suggest - On

### Files

- Auto Guess Encoding - On
- Auto Save - On Window Change
- Insert Final Newline - On
- Trim Final Newlines - On
- Trim Trailing Whitespace

## Workbench

- Command Palette History - 0
- Layout Control Enabled - Off
- Startup Editor - None

### Appearance

- Tips - Off

### Editor Management

- Highlight Modified Tabs
- Untitled Hint - Hidden

### Settings Editor

- Editor - JSON

## Window

- Dialog Style - Custom
- Title Bar Style - custom

## Features

### Search

- Show Line Numbers - On
- Smart Case - On

### Debug

- Console
  - Font Size - 16

### Terminal

- Integrated
  - Cursor Blinking - Off
  - Enable Persistent Sessions - Off
  - Font Size - 16
  - Mac Option Is Meta - On
  - Shell Integration - On

## Application

### Telemetry

- Telemetry Level - Off

## Security

### Workspace

- Trust
  - Untrusted Files - Open

## Extensions

### CSS Language Features

- CSS
  - Completion
    - Complete Property With Semicolon - Off
  - Format
    - Space Around Selector Separator - Off
- SCSS
  - Completion
    - Complete Property With Semicolon - Off
  - Format
    - Space Around Selector Separator - Off

### Git

- AutoFetch - All
- Confirm Sync - Off
- Enable Smart Commit - On

You can get the [JSON file from here.](https://github.com/JannatinNaim/YouTube/blob/main/Videos/1CtLETYekPU/data/settings.json)

PS: If you speak Bangla you can also check out this [YouTube video](https://youtu.be/1CtLETYekPU) showcasing these settings.
Day 594 : One Step Ahead
Tags: hiphop, code, coding, lifelongdev
Published: 2022-07-15 21:52:39

_liner notes_:
- Professional : So, there was a memo that went out saying that for the next few Fridays, we can take the afternoons off. That was cool. I created a demo application to implement a feature and ran into a issue. Think I'll have to hit up the team on Monday.

- Personal : Went through a bunch of tracks for the radio show last night and watched a couple of episodes of "The Rising of the Shield Hero" anime.

![Looking through a forest in Harz, Germany with the setting sun shining through the trees](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/bcja86w7vsokun8j2xwt.jpg)

Going to finish putting together the radio show. I actually have enough tracks already set up for the next show, but I want to add more to keep at least one step ahead. Also want to watch another episode of "The Rising of the Shield Hero". It's getting pretty good. Depending on the time, I may work on my side project.

Have a great night and weekend!

peace piece
Dwane / conshus
https://dwane.io / https://HIPHOPandCODE.com
{% youtube J2XiS6EFwPE %}
The Event Loop
Tags: javascript, webdev, beginners, programming
Published: 2022-07-15 21:52:29

The event loop model gives javascript the possibility to handle many operations like I/O in a non-blocking way even though it’s a single threaded language.

###Visual representation

![The event loop model](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/sjxphnpnw5b75uiuhqc3.jpg)

##Stack
A stack is a data structure that follows the principle of Last In First Out (LIFO), This means the last element inserted inside the stack is removed first, in js every invoked function get pushed to the stack and when it finishes, it is popped from the stack.
```javascript
const last = ()=>{
  console.log("last")
}
const first = ()=>{
  last()
  console.log("first") 
}
first()
/*
last 
first
*/
```
##Heap
Objects are allocated in a heap which is just a name to denote a large (mostly unstructured) region of memory.
##The event Loop 
The event loop is as it sounds a loop that put events on the queue and wait till the stack gets empty then it pushes the events handlers to the stack to get executed.
```javascript
const foo = ()=>{
 console.log("first")
}
setTimeout(()=>{
  console.log("second")
},0)
foo()
/*
 first 
 second
*/
```
***setTimeout*** is a webApi that has a minmum (not an exact) delay time to execute its callback. in this example the event loop put ***setTimeout*** in the queue and the foo function to the call stack, when the function foo executes, the stack becomes empty and then the event loop pushes ***setTimeout*** callback to the ***call stack.***
##Conclusion
The event loop model gives javascript the possibility to handle many operations like I/O in a non-blocking way even though it’s a single threaded language.