» Home » time » Page 1
Execute CommandA A% of time, CommandB B% of time, CommandC C% of time --— CommandZ Z% of time by using Random Number
by Justin Chen in Programming Languages

Problem Statement: Execute Various Command randomly by matching its percentage.
like execute CommandA 50% of time and commandB 25% of the time and commandC 15% of time and etc etc and total percentage should be 100%.

My Question is- Execute CommandA A% of time, CommandB B%
of time, CommandC C% of time ----- CommandZ Z% of time.
And total perce

Ruby can only show local time and Greenwich Mean Time (UTC) but not East Coast Time or Central Time?
by Mcad in Programming Languages

$ irb

ruby-1.9.2-p0 > RUBY_DESCRIPTION
=> "ruby 1.9.2p0 (2010-08-18 revision 29036) [x86_64-darwin10.4.0]"
ruby-1.9.2-p0 > Time.now
=> 2010-09-07 18:18:38 -0700
ruby-1.9.2-p0 > Time.now.gmtime
=> 2010-09-08 01:18:43 UTC
ruby-1.9.2-p0 > Time.now.strftime('%H:%M %Z')
=> "18:22 PDT"
ruby-1.9.2-p0 > Time.now.gm

Converting any date time from server time to user time (dealing with standard and daylight time)
by patrickcarver in Programming Languages

I am working on a web app using .NET MVC 3 and SQL server 2008 (r2).

Anyway, I have a date time object and I want to convert it to user time. It is fairly trivial to convert right now to user time; I have some java script that will get me the users offset from UTC. And I know my date times offset to UTC.

What I realized yesterday, is that my user's offsets will change, i

Get time of different Time zones on selection of time from time picker
by ms-access in Programming Languages

I have an issue of converting selected hours and minutes to different time zones of countries.
Supposing if i select 10 am in India then i want to know at 10 am in india what will be the time in USA/New york and Tokyo.and Vice versa.

Any help is appreciable...
Thank you

Compare Round Robin and Multilevel Feedback Queue in terms of waiting time, response time, turnaround time
by DJ-phYre in Network & Servers

I want to make a comparison between RR and MLFQ in terms of waiting time, response time, turnaround time in 3 cases:

a) More CPU-bounded jobs than I/O

b) More I/O-bounded jobs than
CPU bounded jobs

c) When only a few
jobs need to schedule.

Could you help me to clarify or give me some sources for reference. Thanks

How to time-bound a computation in Java and be able to get all the results computed so far, even when the time budget ends (time-out)?
by tolis626 in Java

In a framework I'm developing the user can choose to run a certain time consuming task in background while doing something else. That task computes a series of results. In some point, when he/she needs the results from the background task, it's acceptable to wait some more time until:

a) a time-out occurs (in this case the user would like to get all the results computed so far, if

Django Templates: How to show the time differences between a Datastore time and current time?
by swinaz in Development Tools & Services

I am working on a django- Google app engine project. A user inserts some value and the datetime field is auto filled using google app engine DateTimeProperty(auto_now_add=True) property. Now, I have to display on the template the difference of this time and the current time when the user is viewing the result.

For e.g. if the inserted time was 5:00 and the user is viewing the post a

How to get the current local time using the system time zone and UTC time from the server in javascript
by loki8481 in Javascript

I have got the UTC time as Sat, 19 May 2012 11:26:51 +0000 in the json response and have the system time zone as +0530. How can i convert the UTC time to the local time using the two available result? I want the date as isoDate format and time as isoTime format. Please help how to do that?

mysql time slot query with a start time and end time and over running times
by Gilmar Souza Jr. in Programming Languages

I have a mysql query that returns time slots. I have a table called timeslots that contains starttimeb, endtimeb and employeeb. Booked Starttime and endtime fields pull from a different table called schedule. The problem is I can only assign appointments defined by the timeslots table.

For example I would like slots 8:00 to 10:00, 10:00 to 12:00, 12:00 to 14:00, 14:00 to 16:00

Calculate time equivalent respective to a users time zone and a fixed time in PHP
by mii in PHP

Below is some text I am working on that tells users what time an online sale begins respective to their local time zone. The online sale always begins at 9am Pacific Time, but not every day.

Our online sale begins at 9am PDT. Your local time, based on your
time zone setting, is September 11, 2012 - 12:02 am HST, which is
UTC -10 or 3 hours behind PDT. The sale will b

Privacy Policy - Copyrights Notice - Feedback - Report Violation - RSS 2017 © bighow.org All Rights Reserved .