teleren/devto huggingface dataset:
CSS code
Published: 2021-07-12 19:36:27


In this blog I will teach you guys a lot of css code that individuals could use to make their applications more attractive for users. 

Scenario 1:
1. html- <p>I love icecream</p>
   css- p {
font-size: 13px;
font:color:blue;
text-align:center;
font-family:poppins;
background:green;
}

Font-size is used when you want to customize the size of your fonts. font-color is used for changing the color of your font. On the other hand, text-align is used so you can align your text accordingly. Such as, center, right, left, bottom, etc. The font-family is used to show what family of font you want to use. For example, Times New Roman, poppins. Lastly, the background is used to change the background color of your website. 

Scenario 2: 

2.  float:right;
    width: 600px
    height: 300px;
    margin:20% 30%;

Float is used to move your text around. Such as moving it to the bottom, right, or left. width is used to adjust the width of your image and height is used to adjust the height. Lastly, the margin is used to create space around the elements outside the border. 

This link will show you the output of how it would look after putting all of these css code. 

Here is the output you would get by doing all this css code- https://codepen.io/sameersheth/pen/mdmObVr

* {
padding:none;
border:none;
text-transform: uppercase;


}
The border is used to define the line styles on all four sides of an element. the padding is used to create space around the element. Text-transform is basically used to make the text on your application uppercase or lowercase. 

p {
background: url(...);
For background url, you just search up the background you want on the browser and then copy the image address and put it inside the parentheses.
Angular NgRx/Store Tutorial Series
Tags: angular, ngrx, typescript, javascript
Published: 2021-07-12 19:10:21

Hello everyone, I'm dreevo and I'm new in the youtube community..I just wanted to share my youtube videos that I started posting about angular and ngrx if you're interested, you can check them out here : https://www.youtube.com/channel/UCF3QsixhylSFAC-s87xa-jw

I would really appreciate some support thanks !
I'm Making a New V. Pet
Tags: gamedev, unity3d, sideprojects
Published: 2021-07-12 18:50:02

The rumors are true.... I'm making a new virtual pet! Last time around, I made [S. Pet](https://avknights.itch.io/s-pet), a retro v. pet inspired by Tamagotchi, Digimon, and the v. pets of my childhood. Someday I'd love to make a pet that's a physical, pocket-sized toy, but S. Pet was native to Android, and my new pet, called **G. Pet**, is in development for Mac, Windows, and Linux.

G. Pet, like its predecessor, is inspired by old toys and rendered in a retro video game style. G. Pet uses a [PSX-style pipeline](https://github.com/pastasfuture/com.hauntedpsx.render-pipelines.psx) and features 3D graphics and even **physics**. Watch your pet walk around the stage, drop in a boombox with five original tracks, plus push it all around with Unity physics (you can push your pet's poop, too). Another big distinction for G. Pet is that each pet will be sold as an individual adoption. Everybody will have a pet unique to them (DRM-free, of course). For now, G. Pet is in free alpha, and everybody can get a behind-the-scenes peek via George the giraffe/tortoise thing.

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

I've already pushed a few rounds of updates on itch.io. You can read more about the early development on the [devlog over there](https://avknights.itch.io/g-pet/devlog). Now I'm starting a new series for G. Pet stuff here on Dev; it might turn into reposts of the devlog at itch.io, or it might be more like digests or ruminations on the process. Not sure yet! Thanks for tuning in though, and don't forget to [download the G. Pet alpha here](https://avknights.itch.io).
We are RunX
Tags: opensource, aws, github, startup
Published: 2021-07-12 18:41:23

Over the last 10 years, our team has built and led Devops teams at world-class companies like Lyft, Twitter, Facebook and Flexport. We have always believed that Devops is a force multiplier - a well built infrastructure can empower the engineers and greatly accelerate product delivery. We saw this first hand at Twitter and Flexport - where the velocity of features slowed down to a trickle due to broken and complicated infrastructure. And it was finally revitalized by amazing Devops and infra advances.

These experiences compelled us to start RunX - our goal is to synthesize years of expertise and package it as a service - to enable the next wave of revolutionary companies. We want every company to have the same infrastructure leverage as Facebook or Twitter. We want every Devops engineer to finally be free of monotonous operational issues and instead focus on solving the problems that are unique to their company. And finally, we want to bring the power of Docker and Kubernetes to every single organization. 

RunX's mission is to supercharge every Devops team and we'd love for you to join us on this journey - https://runx.dev/
LeetCode - 1 : Two Sums
Published: 2021-07-12 18:40:09

Let's discuss the 'Two Sums' problem on LeetCode.
The problem link can be found [here](https://leetcode.com/problems/two-sum/)

<h2> Brute Force Approach [O(n<sup>2</sup>)]</h2>

1. Create an integer vector (_res_) to store the indices.
2. Iterate the given array for all the possible index combinations, such that indices are different.
3. Add the numbers at these two indices at check if it equal to _target_
4. If equal, push the indices into the _res_ vector and break the loop.
5. Return the _res_ vector.

```cpp
vector<int> twoSum(vector<int>& nums, int target) {        
        //Brute Forece Apprach
        vector<int> res;
        for(int i=0;i<nums.size();++i){
            for(int j=i+1;j<nums.size();++j){
                if(nums[i]+nums[j]==target){
                    res.push_back(i);
                    res.push_back(j);
                    break;
                }
            }
            if(res.size()==2){
                break;
            }
        }
        return res;        
    }
```
<h2> Optimized Approach [O(n)] </h2>
<ol>
<li> Create integer vector to store the result. </li>
<li> Create a hash table. </li>
<li> Iterate through the _nums_ vector. </li>
<ol>
 <li type='a'> Find the difference between _target_ and current element.</li>
 <li type='a'> Check if the difference value exists in the hash table. </li>

 <li type='a'>If it does, push the current index and index value from the hash to the vector and return the vector. </li>
 <li type='a'>If it does not, then push difference as the key and index as the value in the hash table and continue</li>
</ol>
</ol>

```cpp
 unordered_map<int,int> map;
        vector<int> res;
        for(int i=0;i<nums.size();++i){
            if(map.find(target-nums[i])!=map.end()){
                res.push_back(i);
                res.push_back(map[target-nums[i]]);
                return res;
            }
            map[nums[i]] = i;
        }
        return res;
```
WHITE PAPER: Natural Language Processing for Text Analytics
Tags: nlp, naturallanguageprocessing, textanalytics, analytics
Published: 2021-07-12 18:39:41

![Natural Language Processing for Text Analytics](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zhkjz2qe9d7www4tl54w.jpg)

###### *I recently co-authored this white paper with Rob Chang, who leads Model Development and Model Validation projects for Commercial and Federal financial institutions at FI Consulting, in Washington, D.C.*<br><br>

Information-rich text is everywhere—emails, chat transcripts, academic journals, newspaper articles—but extracting insights from unstructured text data poses a challenge for many organizations.

Annually, organizations spend millions of dollars manually reviewing text documents; however, the manual review process is often error-prone, inconsistent, and unable to scale. Fortunately, recent advances in technology have enabled machines to understand and parse text more accurately and efficiently than humans. Equipping human text reviewers with text analytics tools can save organizations time and money while providing more thorough and systematic document reviews.

One such use case where text analytics tools can help is with organizations’ requirements to review the thousands of public comments on proposed rulemaking. For example, the Financial Accounting Standard Board (FASB) solicits comment letters from the public on proposed Accounting Standard Updates (ASUs). FASB bases their reasoning for the updates in part on the comments provided. The comments may contain persuasive new data or policy arguments or pose challenging questions and criticisms. Organizations must also filter out fraudulent comments generated by bots or other automated software.

How should organizations proceed to analyze large volumes of public comments in a systematic way?  Entities that do not use text analytics tools may find that their reviewers can only check a small sample of documents, and their reviews are conducted haphazardly, without consistency, controls, or audit trails. This white paper describes our end-to-end text analytics solution that speeds up and enhances manual review while reducing costs. Our solution combines an automated system’s accuracy, speed, and scale with the control and precision of manual review. Our intuitive tools help reviewers extract, parse, and organize large amounts of text, freeing the workforce to focus on the most complex and nuanced text documents.

To download a copy of the entire white paper that discusses how Natural Language Processing can help solve your agencies text analytics challenges, please visit the link below:

[WHITE PAPER: NATURAL LANGUAGE PROCESSING (NLP) FOR TEXT ANALYTICS](https://www.ficonsulting.com/natural-language-processing-for-text-analytics/)
What is AssemblyScript?
Tags: javascript, webassembly, typescript, assemblyscript
Published: 2021-07-12 18:34:40

  ![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/w4uj09a30exiqxep28hd.jpeg)
  AssemblyScript — a variant of TypeScript that compiles to WebAssembly. Since it is compiled, it outperforms JavaScript in some cases. AS follows the TypeScript syntax as closely as possible and even adds more features to it. AssemblyScript allows us to write fast WebAssembly for the Web and Server without learning another language.

  AssemblyScript is very easy to use. All you need to do is install it via NPM.

Try it out online: [Online editor](https://stackblitz.com/edit/node-quzm4z?devtoolsheight=33&file=test.js)

```bash
~ npm i assemblyscript --save-dev
~ npx asinit .
~ npm i
```

What did that do? First of all, it installed both the loader and the compiler. Secondly, it made a template project with an add function. Now, we just need to compile it to WebAssembly.

```bash
~ npm run asbuild
```

So, if you check out the /build folder, there are the .wasm files that were built. NodeJS and JavaScript both provide a way to run WebAssembly files and AssemblyScript provides its own loader to work with the code. To start our code, we need another file

*test.js*
```js
const wasmModule = require('./index')
// This works just like a normal module
console.log(wasmModule.add(2,9))
// -- 11
```

Now, run it!

```bash
~ node test.js
```

It should have outputted the number 11.

JavaScript code for the add function would look like this:

```js
function add(a, b) {
    return a + b
}
module.exports = {
    add: add
}
```

The AssemblyScript code looks like this:

```js
export function add(a: i32, b: i32): i32 {
    return a + b;
}
```

Pretty similar, right? When we compile it, we can require it just like a normal JavaScript file. Keep in mind that WebAssembly is sandboxed which means it can’t access the system, make HTTP requests, or log to the console. However, AssemblyScript supports both WASI and JS bindings (calling JS from AS).

If you have any questions or comments, feel free to comment or join the AssemblyScript Discord. Or, check out the website.😉

P.S: There is a tutorial at https://jtanaka.gitbook.io/guide/
Need some advice, trying to go from NEET to professional...
Tags: help, career
Published: 2021-07-12 18:30:39

[tl; dr] Trying to get my life together with mental illness, looking for guidance without hating myself back into deep depression.

So, I've been trying to get my depression under control. An idea I had was to "play/pretend professional". A sort of "I'll dedicate however long I can each day towards developing project ideas and resume building a day". I'll admit, I've no idea what I'm doing, I only know that I must try something and that something needs to change. I'm attempting to adopt a growth mindset, despite my conditioning.

## Goals
So I'd like to put myself in this kind of life where I can:
- handle hours and work load
- live independently and be myself
- become a contributing member, where I can do social good

## Present Obstacles
When job seeking (this sound familiar to you?):
- hardly get any communication back
- there are very few positions which I can both physically reach and possibly have skill for (I can't afford to move!)
- my mental health issues can make me *physically* unsafe in response to some postings 
    - negative self talk
    - toxic attitudes of the posters (even including advice posts!)
- may have lost support from insurance after outing myself
- enormous gaps on my resume
- going from being "do what I'm told" to being proactive

I'm trying not to be a victim or child, or why expose myself with asking for help? Or commit time to work to better myself? What matters to me is not fault or blame. It's what I can actually do right now. I'm not interested in "facing final judgement for my sins", but rather to grow and accept feedback, critique, and to continue that loop of growth.

## What I'm Doing
I'm attempting to put together a "resume" website, where I showcase some of my work. Now I know it needs to be presentable. The ideas I've found online are concerning, since I'd like to keep it simple, easy to read, and not distracting.

Resume except here, a work in progress of course:
![WIP screenshot](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/019xezstgldp57marfqk.png)

I'd like to do "exploratory work", and present it on the website, showing that I'm both capable of learning new tech, and skills which an employer may find useful.

My future's rather dark right now. Thanks for any guidance, and please, while I can't stop you, I ask you to consider the impact of your words. So far the community has shown a certain lack of toxicity, which I'm grateful. Thank you for reading!
RSS Feed from Hugo Site With Broken Shortcodes
Tags: devto, blog, rss, jekyll
Published: 2021-07-12 18:09:06

I don't keep up with dev.to for publishing as almost every single post has broken imports from my hugo blog.
For example, gists never work, and require me to convert to the jekyll syntax.
Images often have issues as well. 

Is there some way I can control my dev.to posting, and even better automatically publish from my hugo blog so I don't have to manually do this each time?
(I'm guessing perhaps I'd have to build out a custom api call with github actions or something)
Shhh! Hadoop is working
Tags: bigdata, datascience, database, hadoop
Published: 2021-07-12 18:01:50

Imagine someone with a brain that can store and process zettabytes of data. It is not possible for a "Normal" human to have such powerful brain. But, even though you don't possess a brain with such massive processing and storing capacity, you could use a tool that can do the processing and storing part on your behalf. 
Yes, you guessed it correct - HADOOP!! is what I am talking about.

### What is Hadoop?

It's a tool that can store and process huge amount of data as it follows parallel processing concept and stores multiple copies of the data in different systems so that, if one system fails, you don't lose your data. 

### Hadoop Architecture
There are mainly 4 components of Hadoop
* MapReduce
* Hadoop Distributed File System/HDFS
* Yet Another Resource Negotiator/YARN
* Utilities/Java Library

##### MapReduce
This component work as two units i.e. **Map** and **Reduce**. First, the data set goes as input into map function which is nothing but tuples having key-value pair. These key-value pair then goes to reduce function where the data are shuffled and sorted and then aggregated and written in the file with the help of record writer.

##### HDFS
HDFS is used for storage purpose. It works on master slave architecture where we have **NameNode** as Master and **DataNode** as slave. NameNode instructs DataNode, where and how to store data. It stores the metadata where as DataNode actually stores the data.

##### YARN
Its main task is to **schedule jobs** and **manage resources**. YARN decides when and which task or job is to be performed and how much resources to be allocated to perform the job.

##### Utilities/Java libraries
To run other components of Hadoop (MapReduce, HDFS and YARN) smoothly we need these java libraries. These libraries make sure that incase of any hardware failure or any other unfortunate circumstances Hadoop doesn't crash.

### References
Wanna know more about Hadoop? click on the below links.
[HDFS Architecture](https://hadoop.apache.org/docs/stable/hadoop-project-dist/hadoop-hdfs/HdfsDesign.html)
[YARN Architecture](https://hadoop.apache.org/docs/stable/hadoop-yarn/hadoop-yarn-site/YARN.html)
How top convert decimal to roman numeral in java
Published: 2021-07-12 17:52:42

---
title: How top convert decimal to roman numeral in java
published: true
description: I challenge you to create a function to convert decimal to roman numeral in java. We are a long way from advent of code but I thought a coding challenge could be fun trying to create a good function to convert decimal numbers to roman.
tags:
cover_image: 
---

{% youtube fi2jqF7Dz1c %}

I challenge you to create a function to convert decimal to roman numeral in java. We are a long way from advent of code but I thought a coding challenge could be fun trying to create a good function to convert decimal numbers to roman.
Hoisting in JavaScript
Tags: javascript
Published: 2021-07-12 17:08:52

When a JavaScript function executes it creates a global execution context. There are two-phase in the global execution context. 
- Creation
- Code execution 

In the Creation phase, javaScript allocates the memory to the variables and functions. For the variables, it allocates the placeholder value called **undefined**. In the case of the function, it saves the function to the memory.

So When you called the function before the define the function it works. But in the case of the Variables, it returns the undefined.
How to send email using SMTP server in django?
Tags: django, python, beginners
Published: 2021-07-12 17:06:38

Remember when you we signed-up to an application and received a welcome email or you once forgot your password and got an email with password reset link. This small things adds weight to User Experience.

In this article, we will see how to send emails to our users using Django framework and SMTP server. Without wasting any minute let’s jump to the interesting part.

### Setting up Gmail for django mail API:

In order to use Google SMTP, you should have a gmail account. Next thing you need is to enable **Allow less secure app feature** under account security settings. This feature is used for securing your google account from the apps that are less secure to use it in order to prevent hackers from muddle into your account.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/q8wyo9wwqz16h25ritzy.png)

### Configuring settings.py:

In your settings.py file, add the following configurations.
```
EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
EMAIL_HOST = 'smtp.gmail.com'
EMAIL_USE_TLS = True
EMAIL_PORT = 587
EMAIL_HOST_USER = 'your gmail account'
EMAIL_HOST_PASSWORD = 'your account’s password'
EMAIL_USE_SSL = False
```

**Let’s understand these terminologies:**

**EMAIL_BACKEND:** 
This setting specifies the backend that we will  use for sending an email in Django.

**EMAIL_HOST:** 
This setting is to specify the email service provider.

**EMAIL_USE_TLS:** 
This setting specifies whether the Email uses a TLS connection or not. It is True for Gmail.

**EMAIL_PORT:** 
This is the default setting for Gmail. It is the port used by the SMTP server.

**EMAIL_HOST_USER:** 
The name of the email account which will be used.

**EMAIL_HOST_PASSWORD:**
The password of the email account which will be used.

**EMAIL_USE_SSL:** False for Gmail.

> Note: Your password is visible here so before deploying it encrypt your password or place in a file or server, where only have access.

### Configuring views.py:
Django provides a module named **send_mail**, that we will use to send email to the users. There are many options available for the send_mail but for simplicity we will use only 4 fields.

**subject:**
It contains the subject of the email

**message:** 
It contains the body of the email

**email_from:** 
It is the sender’s mail address.

**recipient_list:** 
It is the receiver’s email address.

```
from django.core.mail import send_mail
from django.conf import settings

def mail(request):
    ...
    subject = 'your subject'
    message = 'your message'
    email_from = settings.EMAIL_HOST_USER
    recipient_list = ['receiver's mail address', ]
    return render(request,'some_page.html')
```

### Configuring urls.py:
```
urlpatterns = [
    path('mail', views.mail, name ='mail'),
]
```

With this your code is ready for sending the email to the users. All you need now is to run the server and check whether your methods are functioning properly. 

That’s was it for this article. Thanks for reading.

You can connect with me on [Twitter](https://twitter.com/shubhHAM_) for any discussions.

Adios.
Update description in contact object whenever a new contact is created or updated
Tags: salesforceforfreshr
Published: 2021-07-12 17:05:36

Problem:

You need to create an apex trigger on the contact object which is fire whenever a new contact is created or updated and show the default description accordingly

Trigger code :

Continue reading . . .
https://salesforceforfresher.wordpress.com/2021/07/08/update-description-in-contact-object-whenever-a-new-contact-is-created-or-updated/