Get the busiest time and day of the week.

I have an e-commerce application.
I was looking for a SQL statement has uses the [orderdate] column.
Then you can determine the busiest time of the week and the slowest time of the week.

e.g.

Friday 14:00
….
Monday 1:00

backup – Time Machine alternatives to clone a mac book to another

Two of the most popular and reliable backup options outside of the use of Time Machine are:

Keep in mind that using something new will still take time, since you will have to clone your data completely from scratch anyway.

Therefore, if you already have a current Time Machine backup, using it to transfer all your files is a good option. Many people simply set it up to do this overnight, so the time it takes is not really a problem.

However, if you have other reasons for not wanting to use Time Machine, then use Carbon Copy Cloner or SuperDuper. They are excellent options.

Traversing a polynomial time chart.

Given a directed graph $ G = (V, E) $ and a starting vertex $ v_1 $.

The edges of the graphics are as follows.

$ {(v_1, v_2), (v_2, v_3), (v_3, v_4) } $

basically down

$ (v_1) -> (v_2) -> (v_3) -> (v_4) $

Can we go through this chart and register the path from $ v_1 $ in $ O (| V |) $ hour?

For example, make a list as $[(v_1, v_2), (v_2, v_3), (v_3, v_4)]$

I'm confused if this takes $ O (| V | ^ 2) $ The worst case is the time because the edges are in a set.

Google Sheets – Run multiple scripts at the same time

I'm very new to this, so I'm not sure what to do. I currently have a spreadsheet that runs a script that allows the rows to move according to the Cell Value in column H (State)

I want to execute a long side of an automatic sort function that will also be sorted by the same H (state) column

Here is a link to the Excel file:
https://docs.google.com/spreadsheets/d/1U9LulscZNKiMd_kv9McZEGdZYbjQNhjCUcr5uWcAabo/edit?usp=sharing

I've been trying for hours ūüėē

onEdit (e) {function

var ss = e.source,
sheet = ss.getActiveSheet (),
range = e.range,
objectives sheet,
columnNumberToWatch = 8; // column A = 1, B = 2, etc.
if (sheet.getName () === "Call Present" && e.value === "Call Completed" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Call completed"
} else if (sheet.getName () === "Call sent" && e.value === "Creating link" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Creating link"
} else if (sheet.getName () === "Call sent" && e.value === "Unlock sent" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Buy / Unlock"
} else if (sheet.getName () === "Call completed" && e.value === "Call sent" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Call sent"
} else if (sheet.getName () === "Call completed" && e.value === "Creating link" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Creating link"
} else if (sheet.getName () === "Call complete" && e.value === "Unlock sent" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Buy / Unblockoxa"
} else if (sheet.getName () === "Call Completed" && e.value === "Faded" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Faded"
} else if (sheet.getName () === "Call Present" && e.value === "Faded" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Faded"
} else if (sheet.getName () === "Creating link" && e.value === "Call sent" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Call sent"
} else if (sheet.getName () === "Creating link" && e.value === "Call completed" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Call completed"
} else if (sheet.getName () === "Creating link" && e.value === "Faded" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Faded"
} else if (sheet.getName () === "Creating link" && e.value === "Unlock sent" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Buy / Unlock"
} else if (sheet.getName () === "Buyout / Unlock" && e.value === "Ported" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "portado"
} else if (sheet.getName () === "Faded" && e.value === "Call Present" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Call sent"
} else if (sheet.getName () === "Faded" && e.value === "Call Completed" && e.range.columnStart === columnNumberToWatch) {
targetSheet = "Call sent"
} else if (sheet.getName () === "Faded" && e.value === "&& e.range.columnStart === columnNumberToWatch) {
targetSheet = "Call sent"
}
ss.getSheetByName (targetSheet)
.appendRow (sheet.getRange (e.range.rowStart, 1, 1, sheet.getLastColumn ())
.getValues ‚Äč‚Äč()[0])
sheet.deleteRow (e.range.rowStart);
}

This was the script I was planning to use to sort this (IDK if it is correct).

Is it possible to execute this script only on the first 3 pages, and have it automatically classified in descending order on the 4th sheet (Buy / Unlock)? The last 2 does not matter?

onEdit () {function
var sheet = SpreadsheetApp.getActiveSheet ();
var range = sheet.getRange (3, 1, sheet.getLastRow () - 2, sheet.getLastColumn ());
range.sort ({column: H, ascending: false});
}

Can I use my UK standard visa (business visit) for the transit visa another time?

I recently attended a business meeting using the standard UK visa. I have a transit through the United Kingdom (one day of stopover) next month, can I use the same visa to leave the airport for that day?

Do you remember what day and time you were born?

I do not :P So do not ask me, but some of you may

beginner: statistical function that calculates the average work time in different months

It is a task of a Ruby course, in which I am currently enrolled:
Ruby Course – Page

It is precisely one of the tasks for the first week.

Next idea:
You are given a list in which the finished work tasks are recorded.
The
{work: "article 1", date: "2017-04-26", time: 20},
{work: "article 2", date: "2017-04-27", time: 27},
...

You must write a function that calculates the daily work time for the different months.
Means: Average daily work time in April, average. time in May, … in June. And so …

A data structure, to work on, was given. Even the result, which is expected for that data structure: {"2017-04" => 40, "2017-05" => 14}.

I was able to write a function, which passed all the unit tests.
Here it is:

#! / usr / bin / ruby
tasks =

The
{work: "article 1", date: "2017-04-26", time: 20},
{work: "article 2", date: "2017-04-27", time: 27},
{work: "article 3", date: "2017-04-27", time: 33},
{work: "article 4", date: "2017-05-05", time: 20},
{work: "article 5", date: "2017-05-06", time: 12},
{work: "article 6", date: "2017-05-14", time: 10},
]# Expected result: {"2017-04" => 40, "2017-05" => 14}
def work_per_month (tasks)
days_aggregate = {}

chores. every do | task |
key = task[:date]

    yes days_aggregate.key? (key)
days_added[key][0]    = days_added[key][0]    + homework[:time]
    plus
arr = []
      arr[0] = task[:time]

      days_added[key] = arr
finish
finish

months_aggregate = {}

days_aggregate.each do | key, task |
parts = key.split ("-")
k = "# {parts[0]} - # {parts[1]} "

yes months_aggregate.key? (k)
months_added[k][0]    = months_added[k][0]    + homework[0]
      months_added[k][1]    = months_added[k][1]    + 1
plus
arr = []
      arr[0] = task[0]
      arr[1] = 1

months_added[k] = arr
finish
finish

avg_hours_month = {}

months_aggregate.each do | key, data |
avg_hours_month[key] = data[0] / data[1]
  finish

avg_hours_month
finish

puts work_per_month (tasks) # Returns {"2017-04" => 40, "2017-05" => 14} 

Keep in mind that I started programming at Ruby just a week ago.

It works and has passed the tests. But I am aware that it is clumsy.

Is there any more elegant way to solve the described task?

Without having this sequence of loops?

var = time () vs time () = var pico8 / lua

time () is a default function in the pico8 game.

I do not understand at all why I get an error when I write:
time () = var

But it's okay if I write (where var is any variable)
var = time ()

What are the rules that dictate the order? This does not make any sense to me.

For some context consider a time function:

time_diff = 0

time_change () function
if time () - time_diff> 1 then
time_diff = time ()
finish
finish

If you change to time () = time_diff ….. it generates an error.

Method executed in events takes time to execute c #

I have a method that when it is executed in some checkboxs it works perfectly but when I execute them through the events of the combobox (SelectedIndexChanged) and of a textbox (KeyPress) the first time it runs without problem, however the second takes as 30 seconds to charge and consume more than 3GB of RAM.

// The method in question is this:
public void updateData ()
        {
            textBox2.Clear ();
            string delimiter = (comboBox1.SelectedItem.ToString ());
            string content = textBox1.Text;
            content = content.Trim ();
            if (checkBox1.Checked)
            {
                while (content.Contains (""))
                {
                    content = content.Replace ("", "");
                }
            }
            if (checkBox2.Checked)
            {
                Content = Regex.Replace (content, "[0-9]"," ");
            }
            foreach (var listboxItem in listBox1.Items)
            {
               content = content.Replace (listboxItem.ToString (), "");
            }
            string[] contentSplited = new string[contenido.Length];
            for (int i = 0; i <content.Length; i ++)
            {
                ContentSplited[i] = content[i].ToString ();
                if (content[i] == Convert.ToChar (delimiter))
                {
                    ContentSplited[i] = " r  n";
                }
            }
            for (int i = 0; i <contentSplited.Length; i ++)
            {
                textBox2.Text + = contentSplited[i];
            }
            text = textBox1.Text;
            result = textBox2.Text;
        }

And the events that execute it are these:

// it works without any type of problem and whatever it is.
private void CheckBox1_CheckedChanged (object sender, EventArgs e)
        {
            update data();
        }
// Those that work the first time, and the second one take and consume ...

private void ComboBox1_SelectedIndexChanged (object sender, EventArgs e)
        {
            update data();
        }
// ------------------------------------------------ ----------------
private void TextBox3_KeyUp (object sender, KeyEventArgs e)
        {
            if (e.KeyCode == Keys.Enter)
            {
                string filter = textBox3.Text;
                textBox3.Clear ();
                if (filter! = "" && filter! = "")
                {
                    listBox1.Items.Add (filter);
                    update data();
                }
            }
        }

I have not worked with events but I do not understand this behavior any help I could use very well!

If you can help …
https://youtu.be/Bb-QZwvz7Jo

Hong Kong – Transit time at the Hong Kong airport

I'm looking to book flights between Mumbai, India and San Francisco, USA. UU On a flight from Cathay in the Pacific. For the trip from SFO to MUM and make a stop at HKIA, the available flight options provide a stop in time of 1 h 15 m or more than 10 h. There is no flight. From what I see on the HKIA website, Cathay flights arrive and depart from Terminal 1. I wonder if the 1h15m scale is enough or if we should go with the longer scale. Travelers are "senior" Indian citizens / holders of passports. Will there be a security check in HKIA again for the traffic I have traveled in the past with a stop of 1 h 10 m, and I do not remember having any problems?

Thank you