teleren/devto huggingface dataset:
Graph Representation
Tags: beginners, javascript, datastructure, graph
Published: 2020-04-30 04:10:18

In [Introduction To Graph Data Structure](https://dev.to/codebondco/introduction-to-graph-data-structure-59l4), we learned

- [What is a Graph data structure?](https://codebond.co/tutorial/javascript/introduction-to-graph-data-structure#whatisagraphdatastructure?)
- [Graph Terminologies](https://codebond.co/tutorial/javascript/introduction-to-graph-data-structure#graphterminologies)
- [Types of graph](https://codebond.co/tutorial/javascript/introduction-to-graph-data-structure#typesofgraph)
- [Application Of Graph]()

In this tutorial, we gonna see two common and recommended ways to represent a graph.

- Adjacency matrix
- Adjacency List

![](https://res.cloudinary.com/codebond/image/upload/v1587284296/adkwzuuiz3mfwmsqt66v.png)

If i asked what are [adjacent](https://codebond.co/tutorial/javascript/introduction-to-graph-data-structure#graphterminologies) node of node "A"? you will find all neighbors connected to node "A" by just looking at the graph.

But the question is how the computer will understand the graph and adjacent of node "A" 🤔???

Well, bear with me, we will make sure that computer understands the graph.

# Adjacency Matrix
![](https://res.cloudinary.com/codebond/image/upload/v1587283050/vpzbq82fgipgb1fj7chp.png)

An adjacency matrix is a 2-dimensional array of size N x N where N is the number of the node.

let 2-dimensional array be adj[ i ][ j ] .
```
adj[ i ][ j ] = 1 means there is edge between node "i" and "j".

adj[ i ][ j ] = 0 means there no edge between node "i" and "j".

lets understand by above example:

adj[ 0 ][ 0 ] = 0 (edge between node 0 and 0)

adj[ 0 ][ 1 ] = 1 (edge between node 0 and 1)

adj[ 0 ][ 2 ] = 0 (no edge between node 0 and 2)

adj[ 0 ][ 3 ] = 1 (edge between node 0 and 3)

adj[ 0 ][ 4 ] = 1 (edge between node 0 and 4)

adj[ 0 ][ 5 ] = 0 (no edge between node 0 and 5)
```
similarly for other node....

## Representation of graph by Adjacency Matrix: javascript
### initialize()
It creates a 2-dimensional array and sets the adjmatrix[row][coloumn] to 0 which means there is no edge between any node.

### addEdge()
It creates an edge between source and destination and destination and source.
{% replit @SaudChougle/Adjacency-Matrix %}


# Adjacency List
![](https://res.cloudinary.com/codebond/image/upload/v1587282716/ertqa2dhmhmv9nmyku3d.png)
> In graph theory and computer science, an adjacency list is a collection of unordered lists used to represent a finite graph. Each list describes the set of neighbors of a vertex in the graph. __Wikipedia

In simple words
In Adjacency List each Node will have a list(array) of his adjacent(neighbor) nodes.

## Representation of graph by Adjacency List: javascript
### addNode()
It creates a new node with an empty list.

### addEdge()
It creates an edge between source and destination by pushing the destination node to the list of the source.
{% replit @SaudChougle/Adjacency-List %}

> This post first published on [codebond](https://codebond.co/tutorial/javascript/graph-representation)
Reprint：Fighting the Space Between Inline Block Elements 
Tags: html, css
Published: 2020-04-30 03:45:07

I have encountered this situation several times, usually I will change the parent font-size: 0; to solve this.

I found a more complete answer：
https://css-tricks.com/fighting-the-space-between-inline-block-elements/
https://translate.googleusercontent.com/translate_c
Meet Status() - An Extension for VS Code
Tags: vscode, javascript
Published: 2020-04-30 02:46:35

# The Extension

I introduce to you, [Status()](https://marketplace.visualstudio.com/items?itemName=Bobj2018.status). An extension that displays HTTP status codes without leaving your favorite editor.

## The Idea

The idea came to me when I was working on a back-end server, and I found myself going back and forth between vscode and an HTTP response code cheat sheet. After searching the vscode extension marketplace, I knew I was onto something great.

The first thing to do was to learn how to create an extension for vscode. I found it a bit difficult to comprehend (still is tbh). After watching a course on Pluralsight (thanks to the #FreeApril), I was, for the most part, ready to get started. 

## Implementation
At first, I didn't know where to start, but after writing the first few lines of code, I knew where I was going. Two hours later, I had a fully functional extension. All that I need to do was add the necessary information to the PACKAGE.json and publish it to the VSCODE marketplace. 

## The Future
I have several ideas I want to implement into the extension, so stay tuned!
Seeking a freelance React developer
Tags: freelance, react, contract, hiring
Published: 2020-04-30 02:36:29

Hey all, I'm looking for a freelance/contract React developer to build out a marketing website. The opportunity involves implementing an existing design using Material UI and the candidate would ideally have experience with Redux and TypeScript. This is a short-term project with potential for more work down the road. Message me for more details along with examples of previous work and a desired hourly rate.
The importance of use User Agent to Scraping Data
Tags: webscraping, python, requests, useragent
Published: 2020-04-30 02:16:16

![User Agent](https://dev-to-uploads.s3.amazonaws.com/i/5v50bq0fqtvzwycioofa.png "Capture from Firefox extension User-Agent Switcher")

Using User Agent isn't a common practice by many scrapers and crawlers developers. But it is important to know that using the correct User Agent can help and make easy the scraping tasks of many websites.

## What is a User Agent?

The User Agent is a text string that the client sends through the headers of a request, and serves as an identifier for the type of device, operating system and browser that we are using. This information tells the server that, for example, we are using Google Chrome 80 browser and a computer with Windows 10. And therefore, the server prepares a response intended for that type of device.

Now I have a developer blog, continue reading this post here: https://hhsm95.dev/blog/the-importance-of-using-user-agent-to-scraping-data/

Thank you!
Twiliohackathon Project Part 2 - The Product 
Tags: twiliohackathon, javascript, aws, serverless
Published: 2020-04-30 01:54:04

# About

I built a serverless application that allows users to text kind words to those that are recovering from COVID-19.

One of the main problems for those recovering from COVID-19 is the isolation from loved ones. You can communicate through other means but this application is for those that don't already have a support network.

# Category
- Interesting Integrations

## What I built
I've built a serverless application that uses the tech below
- AWS Lambda
- AWS API Gateway
- AWS DynamoDB
- AWS FIFO SQS

## Demo Link
[Sign up page](https://encouragementnow.net)

## Link to Code
[Front-End Repo](https://github.com/rosborne132/encouragement-now-site)<br>
[Back-End Repo](https://github.com/rosborne132/encouragement-now-api)


## How I built it
This API was built with the Serverless framework, all tech is listed above. The front end site was built using React and Gatsby. <br>

I was able to expand my understanding of AWS technologies while working on this project. Topics learned include:
- Creating and using API keys
- Serverless development with CircleCI
- Adding lambdas to FIFO SQS queues
- Using the Giphy API
- Improving lambda testing by isolating business logic from the handler


## Additional Resources/Info
- [First Blog Post](https://dev.to/r0b/twiliohackathon-project-part-1-the-setup-4l8g)
- [Get Started With Serverless] (https://www.serverless.com/framework/docs/getting-started/)
- [Get Started With Twilio SMS](https://www.twilio.com/docs/sms/quickstart/node)
BigQueryベストプラクティス (パフォーマンス:1)
Tags: bigquery
Published: 2020-04-30 01:15:23

公式ドキュメントに記載のある「BigQuery best practices」をまとめてみるシリーズ。

今回は[パフォーマンス](https://cloud.google.com/bigquery/docs/best-practices-performance-overview)のプラクティスをまとめます。

_イタリック体はドキュメントに記載のない追加コメント_

# ベストプラクティス
## データソースに関するベストプラクティス
[原文](https://cloud.google.com/bigquery/docs/best-practices-performance-input)

### Control projection — Query only the columns that you need
SELECT *を避けようという話。既出のため割愛。

### When querying a partitioned table, use the _PARTITIONTIME pseudo column to filter the partitions
分割テーブルは _PARTITIONTIME 列でフィルタをする。

### BigQuery performs best when your data is denormalized
スキーマの非正規化を行う。

* 正規化によるストレージ容量の節約効果は薄い
* 正規化してJOINする場合、通信等のオーバーヘッドがあるが、非正規化する場合は個別のスロットで並列化されるためパフォーマンスが向上する。
* 非正規化した上でリレーションを保つには、nested field（REPEATEDやSTRUCT）を利用する。
* ただし、以下のような場合は非正規化を避ける
 * スタースキーマにおいてディメンジョンの変更頻度が高い
 * OLTPとしての利用（そもそもBigQuery自体が適していないと思うが）

### If query performance is a top priority, do not use an external data source
パフォーマンスが大事なら、外部データソースは利用しない。

* Cloud StorageやGoogle Driveをデータソースとして利用できるが、BigQueryにデータを格納するよりもパフォーマンスは悪くなる
* 外部データソースは以下のケースで利用する
  * ETL
  * 頻繁に変更されるデータ
  * 定期的なデータ取り込み

### When querying wildcard tables, use the most granular prefix possible
複数テーブルに対してワイルドカードを用いたクエリをする場合は、できる限り絞り込んだ表現を利用する。

* 例えばdata_2010のような末尾が年度になっているテーブルがあるとして、2010年台のデータのみが欲しいのであれば、FROM data_201*は、FROM data_*よりも対象テーブルが少ないため好ましい。

## スロット間のデータ移動（shuffle）に関するベストプラクティス
[原文](https://cloud.google.com/bigquery/docs/best-practices-performance-communication)
_中身は少しタイトルとあっていないかも。JOINとシャーディングの話が中心_

### Reduce the amount of data that is processed before a JOIN clause
JOINの前に、データ量を削減する

* JOINはshuffle（データの移動とマージ）が行われるため、shuffleが実行される以前にデータ量をwhere区などで削減することでパフォーマンス改善につながります。

### Use WITH clauses primarily for readability
With句はリーダビリティのためだけに利用する。マテリアライズされるわけではないので、参照するたびにクエリが実行されます。

### Do not use tables sharded by date (also called date-named tables) in place of time-partitioned tables
日付ごとにテーブルを作るのではなく、[パーティション分割テーブル](https://cloud.google.com/bigquery/docs/partitioned-tables)を利用する。

* 日付ごとにテーブルを作るアプローチは、以下のオーバーヘッドがある。
  * 個別のテーブルごとにメタデータを保持する
  * クエリ実行時に個別のテーブルごとに権限を確認する必要がある
* _ちなみに、日付分割されたテーブルで、読み込むテーブルを緻密に絞るには`_TABLE_SUFFIX`擬似列を利用する。

### Avoid creating too many table shards. If you are sharding tables by date, use time-partitioned tables instead.
１個上で紹介したものと同じ。)
Awareness is Huge
Tags: beginners, career, productivity
Published: 2020-04-30 01:14:38

In addition to being able to learn and improve your dev skills, very important factors for being more likeable and progressing your career are:

1) being able to identify other people's preferences, likes and dislikes
2) intentionally moulding how others see you

Every single word you say, every word you don't say, every laugh, every smile, every frown, every yes, every no, whether you say 'yes', 'ya', 'yep' or 'yea', will alter how people think about you, consciously or subconsciously, for better or worse.

Essentially, treat all of your coworkers as if they are someone you are interested in getting to know well.

Things to pay attention to:

- What ruins their day? No morning coffee? late night deployments? Sitting in meetings? Listening to Fred talk for more than 4 minutes?

- What results in a good mood? A good dinner the night before? Watching Netflix for 7 hours? Finishing a feature? Hanging out with friends?

- What do they like to do in their free time? Most people welcome an opportunity to talk about things they enjoy

- does Tom like to chit-chat before getting asked work questions? Does he prefer to have you get straight to the point?

- When Tom is having a bad day, does any of ^that^ change? What about a great day?

- does Tom prefer to be emailed, or pinged on Slack?

You have the opportunity to present a slightly different version of yourself to each person you interact with, and I recommend doing so.

The takeaway from this is that whether you decide to work on becoming more aware of how others perceive you or not, does not change the fact that people's perceptions of you have the potential to change every single day, and you have the opportunity to make the most of it.
Typeform Handler - Extract phone number and call user
Tags: twiliohackathon
Published: 2020-04-30 00:51:16

---
title: Typeform Handler - Extract phone number and call user
published: true
description: My submission to the Twilio x DEV Hackathon!
tags: twiliohackathon
---

## What I built
#### Category Submission: Engaging Engagements
A simple way to connect a typeform to Twilio, and call a user when the form is submitted.
A simple example good candidate for a code exchange code sample.

## Demo Link
https://picsoung.typeform.com/to/VN616s

## Link to Code
https://glitch.com/~tf-twilio

## How I built it (what's the stack? did I run into issues or discover something new along the way?)
Express app hosted on Glitch 


## Additional Resources/Info
Set up a blog with Gatsby, GitHub pages and GitHub actions
Tags: gatsby, github, pages, actions
Published: 2020-04-30 00:45:45

---
title: Set up a blog with Gatsby, GitHub pages and GitHub actions
published: true
description: 
tags: [ 'gatsby', 'github', 'pages', 'actions' ]
---

_Originally posted at [xkoji.dev](https://www.xkoji.dev/blog/set-up-a-blog-with-gatsby-github-pages-and-github-actions/)_.

This is my first post on my new blog! How exciting! Creating this blog was an interesting process for me since I decided to use Gatsby for it. While I had created a [gatsby plugin](https://www.gatsbyjs.org/packages/gatsby-plugin-altair-graphql/) before, I hadn't actually built anything with gatsby. Starting this new blog was an opportunity to change that.

For my setup, I decided to start off with hosting the blog on [GitHub pages](https://pages.github.com/). [GitHub actions](https://github.com/features/actions) made sense as the perfect tool for continuous deployment of the site, which also happened to be the first time I am using GitHub actions.

After a couple of hours spent figuring out how to properly setup everything, I finally had the blog live and running at [xkojimedia.github.io](https://xkojimedia.github.io/) with a minimal template.

Here I would go over how I was able to setup everything.

...

Continue reading at: https://www.xkoji.dev/blog/set-up-a-blog-with-gatsby-github-pages-and-github-actions/
How To Validate Katacoda Scenarios with GitHub Actions
Tags: github
Published: 2020-04-30 00:40:34

[O’Reilly Katacoda](https://www.katacoda.com/) is an online system that allows developers to develop technical teaching materials online very easily, using JavaScript and Markdown. Course content is run in Docker containers online, and gives a very real feel to learners. They can experiment in a shell from their web browser.

Katacoda projects are created on your development system, and pushed to a GitHub repository, where they are rendered by Katacoda by means of a webhook. This process does not allow you to test your changes locally before you publish, even though Katacoda has a rudimentary CLI. Since mistakes in course content can happen, it is a good idea to set up a GitHub Actions workflow to validate your project. It is quite simple to set this up.

First, read up on how to create a [basic GitHub Actions workflow](https://help.github.com/en/actions), and create one for your project. It will look something like this:

```yml
name: Validate Katacoda
on: push
jobs:
  build:
    name: Validate
    runs-on: ubuntu-latest
    steps:
    - id: checkout-code
      name: Checkout code
      uses: actions/checkout@v2
```

Next, install the Katacoda CLI in your GitHub Actions runner, by adding this step:

```yml
    - id: install-katacoda-cli
      name: Install Katacoda CLI
      run: |
        sudo npm i katacoda-cli --global
```			

Now, you are ready to run the validation. Add the following step to your workflow:
```yml
    - id: validate
      name: Validate Katacoda scenarios
      run: |
        katacoda validate:all --repo ${{ github.workspace }}
```

That's all. Once you commit and push this workflow, it will run each time you make a change to your Katacoda course content, and validate your project.

However, if you want to go over and above for extra credits, you can use Markdown Lint to validate your Katacoda Markdown files.

Add the following step to your workflow:
```yml
    - id: validate-markdown
      name: Validate Katacoda Markdown
      run: |
        sudo gem install mdl
        mdl ${{ github.workspace }}
```
A better way to publish CSVs
Tags: database, sql
Published: 2020-04-30 00:21:55

I'm the CEO of the company that built [Dolt](https://github.com/liquidata-inc/dolt) and [DoltHub](https://www.dolthub.com). Dolt is as if Git and MySQL had a beautiful baby. DoltHub is GitHub for Dolt, a place on the internet to share Dolt repositories.

[I wrote a blog about how to publish CSVs on DoltHub so you can do it too](https://www.dolthub.com/blog/2020-04-29-dolt-dolthub-publish-csv/).

This blog uses the [Tatoeba sentence translation database](https://tatoeba.org/eng/) as an example. It's a collaborative database of sentence translations that is published weekly.

Check it out and publish some data. Pretty please.
Azure - Resource Group DEFAULT-EVENTGRID
Tags: azure, eventgrid
Published: 2020-05-01 09:49:34

---
title: Azure - Resource Group DEFAULT-EVENTGRID
published: true
date: 2020-04-30 00:00:00 UTC
tags: azure, event grid
canonical_url: 
---

If, like me, you logged into your Azure portal this morning, you may have seen a new resource group called **DEFAULT-EVENTGRID** located in West US 2 (at least for me).

As the name suggests, there is a connection with Event Grid ….

Let’s take a look at its content now, a priori there is nothing, unless you activate the hidden resources, you will see a resource of this type _microsoft.eventgrid/systemtopics_

The name of the resource is a simple concatenation of 2 GUIDs.

Now, if you have localization constraints for your resource groups, or if you like everything to be tidy in its place, it’s possible to create your event grid subscription from an ARM template rather than portal.

Here is an ARM template which creates a topic on updating subscription resources, and which sends the messages to a storage queue.

```
{
  "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
  "contentVersion": "1.0.0.0",
  "parameters": {
    "eventSubName": {
      "type": "string",
      "defaultValue": "subToResources",
      "metadata": {
        "description": "The name of the event subscription to create."
      }
    },
    "eventGridTopicName": {
      "type": "string"
    },
    "storageName": {
      "type": "string"
    }
  },
  "resources": [
    {
      "name": "[parameters('eventGridTopicName')]",
      "type": "Microsoft.EventGrid/systemTopics",
      "location": "global",
      "apiVersion": "2020-04-01-preview",
      "properties": {
        "source": "[subscription().id]",
        "topicType": "microsoft.resources.subscriptions"
      }
    },
    {
      "type": "Microsoft.EventGrid/systemTopics/eventSubscriptions",
      "name": "[concat(parameters('eventGridTopicName'), '/', parameters('eventSubName'))]",
      "apiVersion": "2020-04-01-preview",
      "dependsOn": [
        "[parameters('eventGridTopicName')]"
      ],
      "properties": {
        "destination": {
          "endpointType": "StorageQueue",
          "properties": {
            "queueName": "eventgridqueue",
            "resourceId": "[resourceId('Microsoft.Storage/storageAccounts', parameters('storageName'))]"
          }
        }
      }
    }
  ]
}

```

And voila, I was able to delete this resource group located in West US 2.
Metasearch engine in html + google a great utility 
Tags: css, javascript, php, beginners
Published: 2020-04-29 23:40:10

######***IMP REQUEST:***
###### You are most welcome to join my team [ form for joining ](https://forms.gle/pSCALuEWHus3pg9F6).
###### *Also you are most welcome to join OPEN SOURCE INTELLIGENT SYSTEM (OSINT)if you can help in open source project regarding safeguarding humans from various diseases like CORONA outbreak*
######https://github.com/Manishfoodtechs/OSINTHRH/wiki


I keep searching a lot about servers. Now I know that few sites can give me the best answer. So I thought to create a search utility using  Google's multiple site search string. This is the simplest program to save my time. A
Search box creates a 'google string' to search in multiple websites
To Add a new searchable website you need to make change in javascript :OR+site:https://teleconnector.com
Use it for learning or finding job works etc.

**HERE IS LIVE EXAMPLE:**          ***https://manish.imfast.io/***

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/cmjwedzrw38bhf4ujtvr.png)

**TRY TO SEARCH:**             ***What is new in ubuntu 20.04***

Here is my code:
```html
 <html>
 <head>
 <title>Bootstrap Example</title>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css">
  <link href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.0.0-alpha/css/bootstrap.css" rel="stylesheet" />
 </head>
 <body>
  <hr>	
<div class="jumbotron text-center">
  <h1>Meta Search Engine</h1>
  <p>Get results only from the sites you love</p> 
</div>

  <center><div class="col-lg">
    <div class="input-group">
      
      <form onsubmit="return process();">

                            <input class="form-control input-lg" id="url" name="menu_search_bar" placeholder="Search + Press Enter" type="search"  >  </form><br>
							  </div>
    </div></center>
 <!-- Search Script -->
	  <script>
function process()
{
var url="https://www.google.com/search?q="+document.getElementById("url").value+" site:https://digitalocean.com+OR+site:https://teleconnector.com+OR+site:https://dev.to+OR+site:https://www.omgubuntu.co.uk/+OR+site:http://ubuntuhandbook.org+OR+site:https://vitux.com/+OR+site:https://www.techdrivein.com/+OR+site:https://www.linuxbabe.com/+OR+site:http://www.webupd8.org/https://www.scaleway.com/+OR+site:https://linuxconfig.org+OR+site:https://upcloud.com/+OR+site:https://www.techrepublic.com/+OR+site:https://vitux.com/+OR+site:https://www.cyberciti.biz/+OR+site:ovh.com+OR+site:http://www.penguintutor.com/+OR+site:https://www.tecmint.com/";
window.open(url);
return false;
}
</script><!-- Search-->
</body>
</html>
```