teleren/devto huggingface dataset:
What's the PMP Course?
Tags: pmp, pmpcourse, pmpcertification, pmptraining
Published: 2022-06-15 06:13:11

It is the Project Management Professional (PMP)(r) Course  is a widely accepted PMP Course that evaluates a candidate's ability to manage processes, people and the business objectives of an enterprise-level project. There are more than 100,000 PMP Course  holders across the globe According to Project Management Institute (PMI) who administers the certification. It's valid for managers of projects across all industries such as construction, health IT, construction (IT) and business.

To obtain the certification you'll need to be able to meet the required experience requirements and successfully pass an course exam.

**Here's a few important details about this certification:**

 **The PMP course specifications**

To pass the exam you'll have to verify your education and the experience of managing projects. The following are the requirements:

The project manager must complete 35 hours training This is a course that is specifically designed to address learning goals in the field of project management. This could be replaced by an Certified Associate in Project Management (CAPM)(r) certification.
Experience of 36 months in managing projects if you hold an undergraduate degree of four years or more, and 60 months working on projects if you hold an high school diploma or an associate degree.

**PMP exam cost**

The exam cost is $555 for all non-PMI students and 405 dollars for PMI members. A PMI membership cost $129 per year, and the one-time fee of $10 for application that made the exam somewhat cheaper when you have an membership.

**Course for PMP exam PMP exam**

The preparation for the exam requires planning and perseverance; exam guides typically recommend at least a couple of months to study for the exam. There are many courses or books as well as other resources to assist you in studying. Learn more about [PMP course](https://www.edureka.co/pmp-certification-exam-training) getting ready in preparation for your exam.

**The renewal of the Course as PMP course**

PMP course is valid for three years. PMP certification lasts for 3 years, but is able to be renewed or kept by having earned 60 professional development units, which is defined as the number of hours spent on professional development activities within that time frame.
Minimum Operations to Convert Number
Tags: leetcode, dsa, theabbie
Published: 2022-06-15 06:00:46

You are given a **0-indexed** integer array `nums` containing **distinct** numbers, an integer `start`, and an integer `goal`. There is an integer `x` that is initially set to `start`, and you want to perform operations on `x` such that it is converted to `goal`. You can perform the following operation repeatedly on the number `x`:

If `0 <= x <= 1000`, then for any index `i` in the array (`0 <= i < nums.length`), you can set `x` to any of the following:

*   `x + nums[i]`
*   `x - nums[i]`
*   `x ^ nums[i]` (bitwise-XOR)

Note that you can use each `nums[i]` any number of times in any order. Operations that set `x` to be out of the range `0 <= x <= 1000` are valid, but no more operations can be done afterward.

Return _the **minimum** number of operations needed to convert_ `x = start` _into_ `goal`_, and_ `-1` _if it is not possible_.

**Example 1:**

**Input:** nums = \[2,4,12\], start = 2, goal = 12
**Output:** 2
**Explanation:** We can go from 2 → 14 → 12 with the following 2 operations.
- 2 + 12 = 14
- 14 - 2 = 12

**Example 2:**

**Input:** nums = \[3,5,7\], start = 0, goal = -4
**Output:** 2
**Explanation:** We can go from 0 → 3 → -4 with the following 2 operations. 
- 0 + 3 = 3
- 3 - 7 = -4
Note that the last operation sets x out of the range 0 <= x <= 1000, which is valid.

**Example 3:**

**Input:** nums = \[2,8,16\], start = 0, goal = 1
**Output:** -1
**Explanation:** There is no way to convert 0 into 1.

**Constraints:**

*   `1 <= nums.length <= 1000`
*   `-109 <= nums[i], goal <= 109`
*   `0 <= start <= 1000`
*   `start != goal`
*   All the integers in `nums` are distinct.

**SOLUTION:**

    class Solution:
        def minimumOperations(self, nums: List[int], start: int, goal: int) -> int:
            paths = [(start, 0)]
            visited = {start}
            i = 0
            while i < len(paths):
                curr, steps = paths[i]
                if curr == goal:
                    return steps
                if 0 <= curr <= 1000:
                    for num in nums:
                        if (curr + num) not in visited:
                            visited.add((curr + num))
                            paths.append((curr + num, steps + 1))
                        if (curr - num) not in visited:
                            visited.add((curr - num))
                            paths.append((curr - num, steps + 1))
                        if (curr ^ num) not in visited:
                            visited.add((curr ^ num))
                            paths.append((curr ^ num, steps + 1))
                i += 1
            return -1
Create a Google Clone UI using Tailwind CSS
Tags: tailwindcss, css, webdev, tutorial
Published: 2022-06-15 05:56:06

In this short tutorial we will create google search engine ui using tailwind css.
[view](https://larainfo.com/blogs/create-a-google-clone-ui-using-tailwind-css)


### Example
Create a google clone ui  using Tailwind CSS .

```html
<!DOCTYPE html>
<html lang="en">

  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Tailwind CSS Google UI </title>
    <script src="https://cdn.tailwindcss.com"></script>
  </head>

  <body>
    <div class="flex flex-col items-center justify-center h-screen">
      <div class="mb-6">
        <img src="https://www.google.com/images/branding/googlelogo/1x/googlelogo_color_272x92dp.png" alt="google Logo"
          class="object-cover" />
      </div>
      <div class="flex items-center w-full mx-auto mb-4 border rounded-full lg:max-w-2xl hover:shadow-md">
        <div class="pl-5">
          <svg xmlns="http://www.w3.org/2000/svg" class="w-5 h-5 text-gray-400" fill="none" viewBox="0 0 24 24"
            stroke="currentColor" stroke-width="2">
            <path stroke-linecap="round" stroke-linejoin="round" d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z" />
          </svg>
        </div>
        <input type="text" class="w-full bg-transparent rounded-full py-[14px] pl-4 outline-none" />
        <div class="pr-5">
          <svg xmlns="http://www.w3.org/2000/svg" class="w-5 h-5 text-gray-400 text-blue-600 cursor-pointer" fill="none"
            viewBox="0 0 24 24" stroke="currentColor" stroke-width="2">
            <path stroke-linecap="round" stroke-linejoin="round"
              d="M19 11a7 7 0 01-7 7m0 0a7 7 0 01-7-7m7 7v4m0 0H8m4 0h4m-4-8a3 3 0 01-3-3V5a3 3 0 116 0v6a3 3 0 01-3 3z" />
          </svg>
        </div>
      </div>
      <div class="flex gap-x-6">
        <button class="px-3 py-2 text-base font-light cursor-pointer hover:shadow bg-gray-50">Google Search</button>
        <button class="px-3 py-2 text-base font-light cursor-pointer hover:shadow bg-gray-50">I'm Feeling Lucky</button>
      </div>
      <div class="mt-6">
        <div class="text-sm">
          Google offered in: <span class="ml-2 text-blue-700">हिन्दी বাংলা తెలుగు मराठी தமிழ் ગુજરાતી ಕನ್ನಡ മലയാളം
            ਪੰਜਾਬੀ</span>
        </div>
      </div>

    </div>
  </body>

</html>
```
![tailwind google ui](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/wmxkcjsa4th31t7yl4j5.png)
Embeddable Music Player
Tags: html, javascript, css, music
Published: 2022-06-15 05:49:11

Embed a simple HTML music player from local audio on your website using [MediaElement.js](https://www.mediaelementjs.com/) and [Color Thief](https://lokeshdhakar.com/projects/color-thief/). Inspired by Spotify's embed player.

(Fullscreen Live [Demo](https://embeddable-music-player.yizack.com/player/just-stay.html))

{% codepen https://codepen.io/yizack/pen/KKQJQej %}

## Recommended requeriments
- Mp3 audio source.
- Square image.

## Configuration
- Clone or download my repository ([Yizack/embeddable-music-player](https://github.com/Yizack/embeddable-music-player)).
- Edit the file [`/player/song.html`](https://github.com/Yizack/embeddable-music-player/blob/master/player/song.html)
  - Paste your song name in `{SONG-NAME}` for the title of your page.
  - Paste your audio file URL in `{MP3-SOURCE}` for the audio that will be played when you press the play button.
  - Paste your image URL in `{ARTWORK}` for the image that will be displayed.
  - You can also rename or create a new html file to have different players, for example for the live demo I have [`/player/just-stay.html`](https://embeddable-music-player.yizack.com/player/just-stay.html).
  
- Color Thief will detect automatically the dominant color of your song image for your player.

- Use the code below, replace `{YOUR-HTML-PLAYER}` with your HTML filename inside the folder [`/player`](https://github.com/Yizack/embeddable-music-player/blob/master/player) and paste it on your site where you want your audio player to appear.
  ```html
  <iframe src="/player/{YOUR-HTML-PLAYER}.html" width="300" height="385"></iframe>
  ```
  (Example of use on a website using iframes: [Dimatis Website](https://dimatis.yizack.com))
  [![Live Demo](https://yizack.com/images/embeddable-music-player/embeddeds.jpg?)](https://dimatis.yizack.com)

- Thanks to the responsiveness you can play with the width and height as you want.
  ```html
  <iframe src="/player/{YOUR-HTML-PLAYER}.html" width="100%" height="450"></iframe>
  ```
  (Another example of use on a website using iframes: [Dimatis - Fly Again](https://dimatis.yizack.com/music/fly-again))
  [![Live Demo](https://yizack.com/images/embeddable-music-player/embeddeds2.jpg?)](https://dimatis.yizack.com/music/fly-again)
Cloudflare DDNS on Linux
Tags: cloudflare, ddns, dynamic, linux
Published: 2022-06-14 12:13:24

**1. Generate token in `My profile → API Tokens → Create Token` with `Zone.DNS` permission for selected DNS zone.***

Note that it is not possible to select only one subdomain and token will have permission to change all DNS entries.

**2. Use the following script to update DNS entry automatically on your server and save it as `/usr/local/bin/ddns`:**

```bash
#!/bin/bash

# Check for current external IP
IP=`dig +short txt ch whoami.cloudflare @1.0.0.1| tr -d '"'`

# Set Cloudflare API
URL="https://api.cloudflare.com/client/v4/zones/DNS_ZONE_ID/dns_records/DNS_ENTRY_ID"
TOKEN="YOUR_TOKEN_HERE"
NAME="DNS_ENTRY_NAME"

# Connect to Cloudflare
cf() {
curl -X ${1} "${URL}" \
     -H "Content-Type: application/json" \
     -H "Authorization: Bearer ${TOKEN}" \
      ${2} ${3}
}

# Get current DNS data
RESULT=$(cf GET)
IP_CF=$(jq -r '.result.content' <<< ${RESULT})

# Compare IPs
if [ "$IP" = "$IP_CF" ]; then
    echo "No change."
else
    RESULT=$(cf PUT --data "{\"type\":\"A\",\"name\":\"${NAME}\",\"content\":\"${IP}\"}")
    echo "DNS updated."
fi
```

**3. Add script to crontab, so it will be executed every minute:**
```bash
# crontab -e
```
```bash
* * * * * /usr/local/bin/ddns > /dev/null 2>&1
```
Majority Element
Tags: leetcode, dsa, theabbie
Published: 2022-06-15 05:30:42

Given an array `nums` of size `n`, return _the majority element_.

The majority element is the element that appears more than `⌊n / 2⌋` times. You may assume that the majority element always exists in the array.

**Example 1:**

**Input:** nums = \[3,2,3\]
**Output:** 3

**Example 2:**

**Input:** nums = \[2,2,1,1,1,2,2\]
**Output:** 2

**Constraints:**

*   `n == nums.length`
*   `1 <= n <= 5 * 104`
*   `-109 <= nums[i] <= 109`

**Follow-up:** Could you solve the problem in linear time and in `O(1)` space?**SOLUTION:**

    class Solution:
        def majorityElement(self, nums: List[int]) -> int:
            n = len(nums)
            ctr = 1
            maj = nums[0]
            for i in range(1, n):
                if ctr == 0:
                    maj = nums[i]
                if nums[i] != maj:
                    ctr -= 1
                else:
                    ctr += 1
            return maj
This is a way to Grow Your Business Exponentially with Salesforce Einstein
Tags: javascript, python, html, webdev
Published: 2022-06-15 05:19:19

The introduction of Einstein has taken this very good pain and turned it into a gleaming success story for Salesforce. By making data discovery simple and organic, Einstein can produce the foremost of the beautifully difficult AI formula which can bring truth to the forefront. Taking care of customer-oriented and lead-vantage purpose, Einstein seeks to bring degree struggle among the arduous to comprehend number fifty-eight stats.
Einstein brings a helpful prognostic power to sales, promoting and repair among the variability of AI.  Einstein AI is built on a mix of analytical engines that area unit unfold throughout the CRM platform. Commerce Cloud Einstein has seen a 9.6% increase in conversion rate and a 15.5% increase in revenue.  
https://iqratechnology.com/salesforce-einstein-services/

How will Einstein Analytics' implementation assist you to give a far better client experience?
1) Helps generate campaigns by predicting and analyzing the content
2) Enables the Salesforce contact canters to crack deep client insights into mistreatment AI and Machine Learning
3) Recommends the suitable content reckoning on the queries of the purchasers
4) Facilitates CRM to research larger chunks of information 
5) Provides options like Activity Capture, Lead marking, and Insights on objects
6) Increases order worth with the latest options
7) Enables end-users to act on their most vital insights and automates events
https://iqratechnology.com/
Find Words That Can Be Formed by Characters
Tags: leetcode, dsa, theabbie
Published: 2022-06-15 05:00:46

You are given an array of strings `words` and a string `chars`.

A string is **good** if it can be formed by characters from chars (each character can only be used once).

Return _the sum of lengths of all good strings in words_.

**Example 1:**

**Input:** words = \["cat","bt","hat","tree"\], chars = "atach"
**Output:** 6
**Explanation:** The strings that can be formed are "cat" and "hat" so the answer is 3 + 3 = 6.

**Example 2:**

**Input:** words = \["hello","world","leetcode"\], chars = "welldonehoneyr"
**Output:** 10
**Explanation:** The strings that can be formed are "hello" and "world" so the answer is 5 + 5 = 10.

**Constraints:**

*   `1 <= words.length <= 1000`
*   `1 <= words[i].length, chars.length <= 100`
*   `words[i]` and `chars` consist of lowercase English letters.

**SOLUTION:**

    from collections import Counter
    
    class Solution:
        def countCharacters(self, words: List[str], chars: str) -> int:
            chars = Counter(chars)
            l = 0
            for w in words:
                curr = Counter(w)
                possible = True
                for c in curr:
                    if chars[c] < curr[c]:
                        possible = False
                        break
                if possible:
                    l += len(w)
            return l
fluxpoint.py
Tags: fluxpoint, discord, api, python
Published: 2022-06-15 05:00:20


## fluxpoint.py
============

[![Discord server invite](https://discord.com/api/guilds/920190307595874304/embed.png)](https://discord.gg/vfXHwS3nmQ) [![PyPI version info](https://img.shields.io/pypi/v/fluxpoint.py.svg)](https://pypi.python.org/pypi/fluxpoint.py) [![PyPI supported Python versions](https://img.shields.io/pypi/pyversions/fluxpoint.py.svg)](https://pypi.python.org/pypi/fluxpoint.py)

A modern, easy to use, feature-rich, and async ready API wrapper for
Fluxpoint written in Python.

Key Features
------------

-   Modern Pythonic API using `async` and `await`.
-   Proper rate limit handling.
-   Optimised in both speed and memory.

Installing
----------

**Python 3.8 or higher is required**

To install the library, you can just run the following command:

``` {.sh}
# Linux/macOS
python3 -m pip install -U fluxpoint.py

# Windows
py -3 -m pip install -U fluxpoint.py
```

To speedup the api wrapper you should run the following command:

``` {.sh}
# Linux/macOS
python3 -m pip install -U "fluxpoint.py[speed]"

# Windows
py -3 -m pip install -U fluxpoint.py[speed]
```

To install the development version, do the following:

``` {.sh}
$ git clone https://github.com/Dhruvacube/fluxpoint.py
$ cd fluxpoint.py
$ python3 -m pip install -U .[speed]
```

Quick Example
-------------

``` {.py}
from fluxpoint import FluxpointClient
import asyncio
import sys

# setting up the fluxpoint client handler
a = FluxpointClient(api_token="get api token from https://fluxpoint.dev/api/access")

# setting up the windows loop policy according to the operating system
if sys.platform.startswith('win32') or sys.platform.startswith('cygwin'):
    asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())

# getting the image url of AZURLANE image
print(asyncio.run(a.azurlane()))
```

You can find more examples in the [examples
directory](https://github.com/Dhruvacube/fluxpoint.py/tree/master/examples).

---

Links
-----

-   [Documentation](https://fluxpointpy.readthedocs.io/en/latest/)
-   [Official Support Discord Server](https://discord.gg/vfXHwS3nmQ)
-   [Official Fluxpoint server](https://discord.gg/fluxpoint)
-   [Get Fluxpoint api access](https://fluxpoint.dev/api/access)
-   [Official Fluxpoint api docs](https://bluedocs.page/fluxpoint-api)

{% embed https://github.com/Dhruvacube/fluxpoint.py %}
How to Create a VM on Google Cloud With Web Console
Tags: googlecloud, virtualmachine, computeinstance
Published: 2022-06-15 04:50:45

---
title: How to Create a VM on Google Cloud With Web Console
published: true
description: 
tags: googlecloud,virtualmachine,computeinstance
---

Hello, Everyone in this blog i will show you how you can create a virtual machine in Google Cloud.

**Step 1**: Go to Google Cloud Console: https://console.cloud.google.com

Login With your username and password.

**Step 2**: Now Click on the Hamburger Menu and Choose Compute Engine and Click VM Instances.
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/sgnkbzj9s8cgtclnlnq5.png)

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

**Step 3**: If you have a new account click on Enable API
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/aejucy2fo065o33v4as5.PNG)

Wait Few Minutes to Enable The API.
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/95ulu42tohlwc004ktf7.PNG)
After Successfully Enable The API you will see a notification like this.
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5bzn4oive7dxbk3eevdv.PNG)

**Step 4**: Now Click on Create Instance

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

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

Now Click on Create
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/6afesc2zghggggzusc4x.png)

Wait Some Time after few moments your VM Will Created.
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zbyivj9nai9tjwreukgm.png)
After Successfully created your VM you will get information like this.
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/1osfgaupsnu05z9fy2xi.png)

You can now access your VM Via SSH. 
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mll09jgewlu26atmaz8f.png)

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

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

Thanks
100 Days of Code: The Complete Python Pro Bootcamp for 2022 - Day 23 (The Turtle Crossing Capstone Project)
Published: 2022-06-15 04:48:17

- main.py
````python
from turtle import Screen
from player import Player
from car_manager import CarManager
from scoreboard import Scoreboard
import time

# Screen setup
screen = Screen()
screen.setup(width=600, height=600)
screen.bgcolor("white")
screen.title("Turtle Crossing")
screen.tracer(0)

# Class
player = Player()
car = CarManager()
score = Scoreboard()


# Screen settings
screen.listen()
screen.onkeypress(player.go_up, "Up")


# Game logic
game_is_on = True

while game_is_on:
    screen.update()
    time.sleep(0.1)
    car.create_cars()
    car.move_cars()

    # (Turtle)Detect wall contact at y_axis (top of the screen), reset to start position
    if player.ycor() > 280:
        player.reset_position()
        score.point()
        car.level_up()

    # Detect collision with car
    for vehicle in car.all_cars:
        if vehicle.distance(player) < 20:
            game_is_on = False
            score.game_over()

screen.exitonclick()

```
- player.py
````python
from turtle import Turtle

STARTING_POSITION = (0, -280)
MOVE_DISTANCE = 10
FINISH_LINE_Y = 280


class Player(Turtle):

    def __init__(self):
        super().__init__()
        self.showturtle()
        self.shape("turtle")
        self.setheading(90)
        self.penup()
        self.goto(STARTING_POSITION)

    def go_up(self):
        new_y = self.ycor() + 20
        self.penup()
        self.goto(self.xcor(), new_y)

    def reset_position(self):
        self.goto(STARTING_POSITION)

```
- car_manager.py
````python
from turtle import Turtle
import random

COLORS = ["red", "orange", "yellow", "green", "blue", "purple"]
GO_TO = (280, 0)
STARTING_MOV_DISTANCE = 5
MOVE_INCREMENT = 10


class CarManager:

    def __init__(self):
        self.all_cars = []
        self.car_speed = STARTING_MOV_DISTANCE

    def create_cars(self):
        random_chance = random.randint(1, 6)
        if random_chance == 1:
            new_car = Turtle(shape="square")
            new_car.color(random.choice(COLORS))
            new_car.shapesize(stretch_wid=1, stretch_len=2)
            new_car.penup()
            random_y = random.randint(-250, 250)
            new_car.goto(300, random_y)
            self.all_cars.append(new_car)

    def move_cars(self):
        for car in self.all_cars:
            car.backward(self.car_speed)

    def level_up(self):
        self.car_speed += MOVE_INCREMENT

```
- scoreboard.py
````python
from turtle import Turtle

ALIGNMENT = "center"
FONT = ("Courier", 24, "bold")


class Scoreboard(Turtle):

    def __init__(self):
        super().__init__()
        self.hideturtle()
        self.score = 0
        self.penup()
        self.color("black")
        self.update_scoreboard()

    def update_scoreboard(self):
        self.clear()
        self.goto(-205, 260)
        self.write(f"Level: {self.score}", align=ALIGNMENT, font=FONT)

    def point(self):
        self.score += 1
        self.update_scoreboard()

    def game_over(self):
        self.goto(0, 0)
        self.write("Game Over", align=ALIGNMENT, font=FONT)

```