text:
Q: Installing Perl's WWW::Mechanize::Firefox on OpenSuSE 11.4 - resulting in some annoying errors Running OpenSuSE 11.4 - and trying to install WWW::Mechanize::Firefox.
Well I guess that I am missing MAKE (which is obviously GNU make - isn't it?)
See the  following...
cpan[1]> install WWW::Mechanize::Firefox
Going to read '/root/.cpan/Metadata'
  Database was generated on Fri, 09 Dec 2011 00:28:36 GMT
Running install for module 'WWW::Mechanize::Firefox'
Running make for C/CO/CORION/WWW-Mechanize-Firefox-0.58.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/C/CO/CORION/WWW-Mechanize-Firefox-0.58.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/C/CO/CORION/CHECKSUMS
Checksum for /root/.cpan/sources/authors/id/C/CO/CORION/WWW-Mechanize-Firefox-0.58.tar.gz ok
Scanning cache /root/.cpan/build for sizes
............................................................................DONE

  CPAN.pm: Going to build C/CO/CORION/WWW-Mechanize-Firefox-0.58.tar.gz

(Re)Creating lib/WWW/Mechanize/Firefox/Examples.pm
Can't locate HTML/Selector/XPath.pm in @INC (@INC contains: /usr/lib/perl5/site_perl/5.12.3/i586-linux-thread-multi /usr/lib/perl5/site_perl/5.12.3 /usr/lib/perl5/vendor_perl/5.12.3/i586-linux-thread-multi /usr/lib/perl5/vendor_perl/5.12.3 /usr/lib/perl5/5.12.3/i586-linux-thread-multi /usr/lib/perl5/5.12.3 . lib) at ./examples/../lib/WWW/Mechanize/Firefox.pm line 10.
BEGIN failed--compilation aborted at ./examples/../lib/WWW/Mechanize/Firefox.pm line 10.
Compilation failed in require at examples/gen_examples_pod.pl line 32.
Checking if your kit is complete...
Looks good
Warning: prerequisite HTML::Selector::XPath 0 not found.
Warning: prerequisite MozRepl::RemoteObject 0.27 not found.
Warning: prerequisite Object::Import 0 not found.
Warning: prerequisite Shell::Command 0 not found.
Warning: prerequisite Task::Weaken 0 not found.
Writing Makefile for WWW::Mechanize::Firefox
---- Unsatisfied dependencies detected during ----
---- CORION/WWW-Mechanize-Firefox-0.58.tar.gz ----
    Task::Weaken [requires]
    Object::Import [requires]
    Shell::Command [requires]
    MozRepl::RemoteObject [requires]
    HTML::Selector::XPath [requires]
Running make test
  Delayed until after prerequisites
Running make install
  Delayed until after prerequisites
Running install for module 'Task::Weaken'
Running make for A/AD/ADAMK/Task-Weaken-1.04.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/A/AD/ADAMK/Task-Weaken-1.04.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/A/AD/ADAMK/CHECKSUMS
Checksum for /root/.cpan/sources/authors/id/A/AD/ADAMK/Task-Weaken-1.04.tar.gz ok

  CPAN.pm: Going to build A/AD/ADAMK/Task-Weaken-1.04.tar.gz

Checking if your kit is complete...
Looks good
Writing Makefile for Task::Weaken
Can't exec "make": Datei oder Verzeichnis nicht gefunden at /usr/lib/perl5/5.12.3/CPAN/Distribution.pm line 2026.
  ADAMK/Task-Weaken-1.04.tar.gz
  make -- NOT OK
'YAML' not installed, will not store persistent state
Running make test
  Can't test without successful make
Running make install
  Make had returned bad status, install seems impossible
Running install for module 'Object::Import'
Running make for A/AM/AMBRUS/Object-Import-1.002.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/A/AM/AMBRUS/Object-Import-1.002.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/A/AM/AMBRUS/CHECKSUMS
Checksum for /root/.cpan/sources/authors/id/A/AM/AMBRUS/Object-Import-1.002.tar.gz ok

  CPAN.pm: Going to build A/AM/AMBRUS/Object-Import-1.002.tar.gz

Checking if your kit is complete...
Looks good
Warning: prerequisite MRO::Compat 0 not found.
Writing Makefile for Object::Import
---- Unsatisfied dependencies detected during ----
----     AMBRUS/Object-Import-1.002.tar.gz    ----
    MRO::Compat [requires]
Running make test
  Delayed until after prerequisites
Running make install
  Delayed until after prerequisites
Running install for module 'MRO::Compat'
Running make for F/FL/FLORA/MRO-Compat-0.11.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/F/FL/FLORA/MRO-Compat-0.11.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/F/FL/FLORA/CHECKSUMS
Checksum for /root/.cpan/sources/authors/id/F/FL/FLORA/MRO-Compat-0.11.tar.gz ok

  CPAN.pm: Going to build F/FL/FLORA/MRO-Compat-0.11.tar.gz

Checking if your kit is complete...
Looks good
Writing Makefile for MRO::Compat
Can't exec "make": Datei oder Verzeichnis nicht gefunden at /usr/lib/perl5/5.12.3/CPAN/Distribution.pm line 2026.
  FLORA/MRO-Compat-0.11.tar.gz
  make -- NOT OK
Running make test
  Can't test without successful make
Running make install
  Make had returned bad status, install seems impossible
Running make for A/AM/AMBRUS/Object-Import-1.002.tar.gz
  Has already been unwrapped into directory /root/.cpan/build/Object-Import-1.002-0gvgp8

  CPAN.pm: Going to build A/AM/AMBRUS/Object-Import-1.002.tar.gz

Warning: Prerequisite 'MRO::Compat => 0' for 'AMBRUS/Object-Import-1.002.tar.gz' failed when processing 'FLORA/MRO-Compat-0.11.tar.gz' with 'make => NO'. Continuing, but chances to succeed are limited.
Can't exec "make": Datei oder Verzeichnis nicht gefunden at /usr/lib/perl5/5.12.3/CPAN/Distribution.pm line 2026.
  AMBRUS/Object-Import-1.002.tar.gz
  make -- NOT OK
Running make test
  Can't test without successful make
Running make install
  Make had returned bad status, install seems impossible
Running install for module 'Shell::Command'
Running make for F/FL/FLORA/Shell-Command-0.06.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/F/FL/FLORA/Shell-Command-0.06.tar.gz
Checksum for /root/.cpan/sources/authors/id/F/FL/FLORA/Shell-Command-0.06.tar.gz ok

  CPAN.pm: Going to build F/FL/FLORA/Shell-Command-0.06.tar.gz

Checking if your kit is complete...
Looks good
Writing Makefile for Shell::Command
Can't exec "make": Datei oder Verzeichnis nicht gefunden at /usr/lib/perl5/5.12.3/CPAN/Distribution.pm line 2026.
  FLORA/Shell-Command-0.06.tar.gz
  make -- NOT OK
Running make test
  Can't test without successful make
Running make install
  Make had returned bad status, install seems impossible
Running install for module 'MozRepl::RemoteObject'
Running make for C/CO/CORION/MozRepl-RemoteObject-0.28.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/C/CO/CORION/MozRepl-RemoteObject-0.28.tar.gz
Checksum for /root/.cpan/sources/authors/id/C/CO/CORION/MozRepl-RemoteObject-0.28.tar.gz ok

  CPAN.pm: Going to build C/CO/CORION/MozRepl-RemoteObject-0.28.tar.gz

Checking if your kit is complete...
Looks good
Warning: prerequisite IPC::Run 0 not found.
Warning: prerequisite JSON 2 not found.
Warning: prerequisite MozRepl 0.06 not found.
Warning: prerequisite Task::Weaken 0 not found.
Writing Makefile for MozRepl::RemoteObject
---- Unsatisfied dependencies detected during ----
----  CORION/MozRepl-RemoteObject-0.28.tar.gz ----
    MozRepl [requires]
    IPC::Run [requires]
    Task::Weaken [requires]
    JSON [requires]
Running make test
  Delayed until after prerequisites
Running make install
  Delayed until after prerequisites
Running install for module 'MozRepl'
Running make for Z/ZI/ZIGOROU/MozRepl-0.06.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/Z/ZI/ZIGOROU/MozRepl-0.06.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/Z/ZI/ZIGOROU/CHECKSUMS
Checksum for /root/.cpan/sources/authors/id/Z/ZI/ZIGOROU/MozRepl-0.06.tar.gz ok

  CPAN.pm: Going to build Z/ZI/ZIGOROU/MozRepl-0.06.tar.gz

*** Module::AutoInstall version 1.03
*** Checking for Perl dependencies...
[Core Features]
- Carp::Clan                   ...missing.
- Class::Accessor::Fast        ...missing.
- Class::Data::Inheritable     ...missing.
- Data::Dump                   ...missing.
- Data::JavaScript::Anon       ...missing.
- File::Spec                   ...loaded. (3.3101)
- Module::Pluggable::Fast      ...missing.
- Net::Telnet                  ...missing.
- Template                     ...missing.
- Template::Provider::FromDATA ...missing.
- Text::SimpleTable            ...missing.
- UNIVERSAL::require           ...missing.
- URI                          ...loaded. (1.58)
==> Auto-install the 11 mandatory module(s) from CPAN? [Y/n] y

*** Since we're running under CPANPLUS, I'll just let it take care
    of the dependency's installation later.
*** Module::AutoInstall configuration finished.
Checking if your kit is complete...
Looks good
Warning: prerequisite Carp::Clan 0 not found.
Warning: prerequisite Class::Accessor::Fast 0 not found.
Warning: prerequisite Class::Data::Inheritable 0 not found.
Warning: prerequisite Data::Dump 0 not found.
Warning: prerequisite Data::JavaScript::Anon 0 not found.
Warning: prerequisite Module::Pluggable::Fast 0 not found.
Warning: prerequisite Net::Telnet 0 not found.
Warning: prerequisite Template 0 not found.
Warning: prerequisite Template::Provider::FromDATA 0 not found.
Warning: prerequisite Text::SimpleTable 0 not found.
Warning: prerequisite UNIVERSAL::require 0 not found.
Writing Makefile for MozRepl
---- Unsatisfied dependencies detected during ----
----        ZIGOROU/MozRepl-0.06.tar.gz       ----
    Module::Pluggable::Fast [requires]
    Template::Provider::FromDATA [requires]
    Class::Accessor::Fast [requires]
    Data::Dump [requires]
    Class::Data::Inheritable [requires]
    Text::SimpleTable [requires]
    Template [requires]
    Carp::Clan [requires]
    Data::JavaScript::Anon [requires]
    Net::Telnet [requires]
    UNIVERSAL::require [requires]
Running make test
  Delayed until after prerequisites
Running make install
  Delayed until after prerequisites
Running install for module 'Module::Pluggable::Fast'
Running make for M/MR/MRAMBERG/Module-Pluggable-Fast-0.19.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/M/MR/MRAMBERG/Module-Pluggable-Fast-0.19.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/M/MR/MRAMBERG/CHECKSUMS
Checksum for /root/.cpan/sources/authors/id/M/MR/MRAMBERG/Module-Pluggable-Fast-0.19.tar.gz ok

  CPAN.pm: Going to build M/MR/MRAMBERG/Module-Pluggable-Fast-0.19.tar.gz

Checking if your kit is complete...
Looks good
Warning: prerequisite UNIVERSAL::require 0 not found.
Writing Makefile for Module::Pluggable::Fast
----  Unsatisfied dependencies detected during  ----
---- MRAMBERG/Module-Pluggable-Fast-0.19.tar.gz ----
    UNIVERSAL::require [requires]
Running make test
  Delayed until after prerequisites
Running make install
  Delayed until after prerequisites
Running install for module 'UNIVERSAL::require'
Running make for M/MS/MSCHWERN/UNIVERSAL-require-0.13.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/M/MS/MSCHWERN/UNIVERSAL-require-0.13.tar.gz
Checksum for /root/.cpan/sources/authors/id/M/MS/MSCHWERN/UNIVERSAL-require-0.13.tar.gz ok

  CPAN.pm: Going to build M/MS/MSCHWERN/UNIVERSAL-require-0.13.tar.gz

Checking if your kit is complete...
Looks good
Writing Makefile for UNIVERSAL::require
Can't exec "make": Datei oder Verzeichnis nicht gefunden at /usr/lib/perl5/5.12.3/CPAN/Distribution.pm line 2026.
  MSCHWERN/UNIVERSAL-require-0.13.tar.gz
  make -- NOT OK
Running make test
  Can't test without successful make
Running make install
  Make had returned bad status, install seems impossible
Running make for M/MR/MRAMBERG/Module-Pluggable-Fast-0.19.tar.gz
  Has already been unwrapped into directory /root/.cpan/build/Module-Pluggable-Fast-0.19-iMlazZ

  CPAN.pm: Going to build M/MR/MRAMBERG/Module-Pluggable-Fast-0.19.tar.gz

Warning: Prerequisite 'UNIVERSAL::require => 0' for 'MRAMBERG/Module-Pluggable-Fast-0.19.tar.gz' failed when processing 'MSCHWERN/UNIVERSAL-require-0.13.tar.gz' with 'make => NO'. Continuing, but chances to succeed are limited.
Can't exec "make": Datei oder Verzeichnis nicht gefunden at /usr/lib/perl5/5.12.3/CPAN/Distribution.pm line 2026.
  MRAMBERG/Module-Pluggable-Fast-0.19.tar.gz
  make -- NOT OK
Running make test
  Can't test without successful make
Running make install
  Make had returned bad status, install seems impossible
Running install for module 'Template::Provider::FromDATA'
Running make for B/BR/BRICAS/Template-Provider-FromDATA-0.12.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/B/BR/BRICAS/Template-Provider-FromDATA-0.12.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/B/BR/BRICAS/CHECKSUMS
Checksum for /root/.cpan/sources/authors/id/B/BR/BRICAS/Template-Provider-FromDATA-0.12.tar.gz ok
----    Unsatisfied dependencies detected during   ----
---- BRICAS/Template-Provider-FromDATA-0.12.tar.gz ----
    ExtUtils::MakeMaker [build_requires]
Running make test
  Make had some problems, won't test
  Delayed until after prerequisites
Running make install
  Make had some problems, won't install
  Delayed until after prerequisites
Running install for module 'ExtUtils::MakeMaker'
Running make for M/MS/MSCHWERN/ExtUtils-MakeMaker-6.62.tar.gz
Fetching with LWP:
ftp://ftp.hosteurope.de/pub/CPAN/authors/id/M/MS/MSCHWERN/ExtUtils-MakeMaker-6.62.tar.gz
Checksum for /root/.cpan/sources/authors/id/M/MS/MSCHWERN/ExtUtils-MakeMaker-6.62.tar.gz ok

  CPAN.pm: Going to build M/MS/MSCHWERN/ExtUtils-MakeMaker-6.62.tar.gz

Using included version of JSON::PP::Compat5006 (1.09) because it is not already installed.
Using included version of version (0.88) as it is newer than the installed version (0.82).
Using included version of ExtUtils::Manifest (1.58) as it is newer than the installed version (1.57).
Using included version of Parse::CPAN::Meta (1.4401) as it is newer than the installed version (1.40).
Using included version of CPAN::Meta::YAML (0.003) because it is not already installed.
Using included version of JSON::PP (2.27104) because it is not already installed.
Using included version of CPAN::Meta (2.112150) because it is not already installed.
Using included version of File::Copy::Recursive (0.38) because it is not already installed.
Using included version of Version::Requirements (0.101020) because it is not already installed.
Checking if your kit is complete...
Looks good
Writing Makefile for ExtUtils::MakeMaker
Writing MYMETA.yml and MYMETA.json
Can't exec "make": Datei oder Verzeichnis nicht gefunden at /usr/lib/perl5/5.12.3/CPAN/Distribution.pm line 2026.
  MSCHWERN/ExtUtils-MakeMaker-6.62.tar.gz
  make -- NOT OK
Running make test
  Can't test without successful make

Running make test

Any idea what I need to do to fix these problems?
update: many many thanks for the  helpful answers; here some additional informations:
cpan[1]> o conf
$CPAN::Config options from '/usr/lib/perl5/5.12.3/CPAN/Config.pm':
    commit             [Commit changes to disk]
    defaults           [Reload defaults from disk]
    help               [Short help about 'o conf' usage]
    init               [Interactive setting of all options]

    applypatch         []
    auto_commit        [0]
    build_cache        [100]
    build_dir          [/root/.cpan/build]
    build_dir_reuse    [0]
    build_requires_install_policy [yes]
    bzip2              [/usr/bin/bzip2]
    cache_metadata     [1]
    check_sigs         [0]
    colorize_debug     undef
    colorize_output    [0]
    colorize_print     undef
    colorize_warn      undef
    commandnumber_in_prompt [1]
    commands_quote     undef
    connect_to_internet_ok [1]
    cpan_home          [/root/.cpan]
    curl               [/usr/bin/curl]
    dontload_hash      undef
    dontload_list      undef
    ftp                [/usr/bin/ftp]
    ftp_passive        [1]
    ftp_proxy          []
    ftpstats_period    undef
    ftpstats_size      undef
    getcwd             [cwd]
    gpg                [/usr/bin/gpg]
    gzip               [/usr/bin/gzip]
    halt_on_failure    [0]
    histfile           [/root/.cpan/histfile]
    histsize           [100]
    http_proxy         []
    inactivity_timeout [0]
    index_expire       [1]
    inhibit_startup_message [0]
    keep_source_where  [/root/.cpan/sources]
    load_module_verbosity [none]
    lynx               []
    make               []
    make_arg           []
    make_install_arg   []
    make_install_make_command []
    makepl_arg         []
    mbuild_arg         []
    mbuild_install_arg []
    mbuild_install_build_command [./Build]
    mbuildpl_arg       []
    ncftp              []
    ncftpget           []
    no_proxy           []
    pager              [less]
    password           undef
    patch              []
    patches_dir        undef
    perl5lib_verbosity [none]
    prefer_installer   [MB]
    prefs_dir          [/root/.cpan/prefs]
    prerequisites_policy [follow]
    proxy_pass         undef
    proxy_user         undef
    randomize_urllist  undef
    scan_cache         [atstart]
    shell              [/bin/bash]
    show_unparsable_versions [0]
    show_upload_date   [0]
    show_zero_versions [0]
    tar                [/bin/tar]
    tar_verbosity      [none]
    term_is_latin      [1]
    term_ornaments     [1]
    test_report        [0]
    trust_test_report_history [0]
    unzip              [/usr/bin/unzip]
    urllist
        0 [ftp://ftp.hosteurope.de/pub/CPAN/]
        1 [ftp://mirror.checkdomain.de/CPAN/]
        2 [ftp://mirror.fraunhofer.de/CPAN/]
        3 [ftp://ftp.u-tx.net/CPAN/]
        4 [ftp://cpan.noris.de/pub/CPAN/]
    use_sqlite         [0]
    username           undef
    version_timeout    [15]
    wait_list          undef
    wget               [/usr/bin/wget]
    yaml_load_code     [0]
    yaml_module        [YAML]

look forward to hear from you again !! And ineeed - i cant wait to use mecha on this machine.

A: By the looks of it, you do indeed need to install GNU make on your machine.  If any of those modules needs a C compiler, you'll need to install the C development system - which may be quite a number of packages.
The chances are that if you want to install an alternative make program, it will also work.  The easiest one to find, though, will be GNU make.

One of the key items on your CPAN configuration is 'prerequisite_policy [follow]'; that is the most sensible choice. If a prerequisite module is missing, it will be installed automatically. Your trace shows this happening; some of the modules needed are missing, so it tries to install them before installing WWW::Mechanize::Firefox.
The problem is that it keeps failing to find 'make'.  If you have not got 'make' installed, you need to install it.  If you have it installed, you need it on your PATH.  I do note that your config contains:
make               []
make_arg           []
make_install_arg   []
make_install_make_command []

My CPAN configuration (actually on MacOS X 10.7.2, but I don't think that matters) includes:
make               [/usr/bin/make]
make_arg           []
make_install_arg   [UNINST=1]
make_install_make_command [/usr/bin/make]

If you have make installed, set at least the two command names to the correct path (might be /usr/local/bin/make, perhaps, or /usr/bin/make).  The UNINST=1 bit means that code will remove stuff that is no longer needed (because it is out of date) that is in a different directory than where it is about to install the new stuff.  It is a bit arcane, but I've had it like that for a decade or more, AFAICR.  (Mostly, these days, I use CPANPLUS rather than CPAN.)


text:
Q: Separate two words in the same colum in awk cli? In CLI I type:
$ timedatectl | grep Time | awk '{print $3}'
Which gives me the correct output:
Country/City
How can I just get the print out of city without the Country?

A: Use this command instead:
timedatectl | grep Time | awk '{print $3}' | cut -d/ -f2

redpajama_set_name: RedPajamaStackExchange


text:
Q: NSView-based table view with auto layout grows, but does not shrink rows I have a NSTableView in view-based mode (not cell-based) with usesAutomaticRowHeights=YES. The rows have dynamic height that might change at any time. This setup successfully grows table view rows (row content is never clipped), but table view rows don't shrink to the intrinsic row view height when rows get shorter. Calling noteHeightOfRowsWithIndexesChanged: on the table view after layout does not seem to fix the problem, my tableView:heightOfRow: is also not called again after noteHeightOfRowsWithIndexesChanged:.
Is there anything I have missed/isn't documented about using auto layout in NSView-based tableviews with variable row height? After all, growing rows always works without any additional code, they just do not shrink on their own.
NSTableView* tv = [[NSTableView alloc] init];

[tv setTranslatesAutoresizingMaskIntoConstraints:NO];
[tv setUsesAutomaticRowHeights:YES];     // Use auto layout for row height

NSTableColumn* column = [[NSTableColumn alloc] init];
[tv addTableColumn:column];

// Set table view data source and delegate, rows are then loaded...

A: After debugging the default table view layout for a long time, I finally found the issue. The table view row views come with some autoresizingmask settings that interfere with content, when using autolayout for the row content views. You need to set the row view's translatesAutoresizingMaskIntoConstraints to NO. This can be achieved for a view-based NSTableView using the delegate method tableView:(NSTableView *)tableView didAddRowView:(NSTableRowView *)rowView forRow:(NSInteger)row:
- (void)tableView:(NSTableView *)tableView didAddRowView:(NSTableRowView *)rowView forRow:(NSInteger)row
{
    // Remember that rowView != row content view!
    [rowView setTranslatesAutoresizingMaskIntoConstraints:NO];   // Disable constraints interfering with row view content
}

Interestingly, this does not seem to be an issue if content does not shrink past the initial row height or maximum row height it has grown to, due to dynamic height increases.


text:
Q: How to get rid of repeated Data? There is a function like that:
public List<Point> FindNextPoint(List<Point> source, Point point, List<Point> findedPoints)
    {
        List<Point> result = new List<Point>();
        List<Point> points = source.FindAll(
            delegate (Point i)
            {
                return (Math.Abs(i.X - point.X) <= 2 && Math.Abs(i.Y - point.Y) <= 2) && !findedPoints.Contains(i);
            }
            );
        result.AddRange(points);
        findedPoints.AddRange(points);
        for (int i = 0; i < points.Count; i++)
        {
            List<Point> findPoints = FindNextPoint(source, points[i], findedPoints);
            result.AddRange(findedPoints);
        }
        return result;
    }

but it returns many repeated Point in the list,how to get rid of if?Thank you
I mean that everytime I run the function it will return a List,I wonder if there any chance that return a List not including the data before.
for example. I first run the function it returns a value including the Point{x=0,y=1},when I run the function for the second time it will not return the same Point returned before,and will also not FindAll to find it.

A: When returning data you should use this Code:
return result.Distinct();

and don't forget to add the code below on top otherwise you cannot see the Distinct function:
using System.Linq;


text:
Q: Django Reverse for '' with arguments '('',)' and keyword arguments '{}' not found Error I am receiving this error
Reverse for 'option' with arguments '('',)' and keyword arguments '{}' not found.

while I am rendering my option page. The option page is the last page in a 3 part workstream. The first 2 pages work fine. I am not sure why nothing is rendering. My code is below:
views.py
def drui_index(request):
  disease_list = Disease.objects.all()
  context = {'disease_list':disease_list, 'hide_breadcrumb': hide_breadcrumb}
  return render(request, 'drui_index.html', context)

def drui(request, disease_id):
  disease = get_object_or_404(Disease, pk=disease_id)

  if request.method == "POST":
      indicatorInlineFormSet = IndicatorFormSet(request.POST, request.FILES, instance=disease)

      if indicatorInlineFormSet.is_valid():
         indicatorInlineFormSet.save()
         return HttpResponseRedirect(reverse('option', kwargs={'disease_id':disease_id}))

  else:
      indicatorInlineFormSet = IndicatorFormSet(instance=disease)

  return render(request, 'drui.html', {'disease':disease, 'indicatorInlineFormSet': indicatorInlineFormSet})

def option(request, disease_id):

     disease = get_object_or_404(Disease, pk=disease_id)

     if request.method == "POST":
         optionInlineFormSet = OptionFormSet(request.POST, request.FILES, instance=disease, prefix='option')
         outcomeInlineFormSet = OutcomeFormSet(request.POST, request.FILES, instance=disease, prefix='outcome')

        if optionInlineFormSet.is_valid() and outcomeInlineFormSet.is_valid:
           optionInlineFormSet.save()
           outcomeInlineFormSet.save()
           return HttpResponseRedirect(reverse('splash', kwargs={'disease_id':disease_id}))

    else:
        optionInlineFormSet = OptionFormSet(instance=disease,prefix='option')
        outcomeInlineFormSet = OutcomeFormSet(instance=disease,prefix='outcome')

   return render(request, 'option.html', {'optionInlineFormSet': optionInlineFormSet, 'outcomeInlineFormSet': outcomeInlineFormSet})

urls.py
url(r'^drui_index/$', 'Physician_UI.views.drui_index', name='drui_index'),
url(r'^drui_index/(?P<disease_id>\d+)/$', 'Physician_UI.views.drui', name='drui'),
url(r'^drui_index/(?P<disease_id>\d+)/option/$', 'Physician_UI.views.option', name='option'),

HTML drui_index.html
{% load url from future %}
<form class="disease_form" action="{% url "drui_index" %}" method="post">{% csrf_token %}

HTML drui.html
{% load url from future %}
<form class="disease_form" action="{% url "drui" disease.id %}" method="post">{% csrf_token %}

HTML option.html
 {% load url from future %}
 <form class="option_form" action="{% url "option" disease.id %}" method="post">{% csrf_token %}

As I mentioned before, the first 2 pages (drui_index, and drui) work fine but option.html does not. I included most of the code just in case I'm passing information in the wrong way.
I am using django 1.4

A: You should pass disease object in context in your option view. You are not passing disease object in context and in template you are using disease.id hence the error.
return render(request, 'option.html',
    {'optionInlineFormSet': optionInlineFormSet,
    'outcomeInlineFormSet': outcomeInlineFormSet,
    'disease': disease})


text:
Q: CSS Color Doesn't Load for Button Can somebody assist with why the buttons on the page below don't render the background color correctly? The background-color property appears to be set correctly but I'm wondering if there's a conflict with another CSS file my template is using. Any advice?
http://www.chrisboulasphotography.com/store/ferrari-owners-manuals

A: This gradient (defined in /wp-content/w3tc/min/1088176c.f6146a.css on line 379) is clobbering the background property...
background-image: -moz-linear-gradient(center bottom , #F0F0F0 2%, #FAFAFA 51%);

A: Alex answered this perfectly right. Using Firefox with Firebug I have been able to disactivate the css line he suggested and it seems that the background color of your buttons appears again.
Have you emptied you cache to check if it's not your browser who has kept the old css in memory?


text:
Q: The License Plate Game Premise: So, my father came up with a game where you would look at a 4-digit license plate make 2 pairs of numbers that were made from 2 of the digits from the license plate and were Identical Odd Numbers.
Some example games may be:
$$
  \begin{align}
  \fbox{ΑΒΕ 5409} & \rightarrow 5+4=9 \\
                  & \rightarrow 9+0=9 \\
                  & \rightarrow 9,9 \\
  \end{align}
$$
$$
  \begin{align}
  \fbox{ΗΙΚ 3162} & \rightarrow 3\times1=3 \\
                  & \rightarrow \frac{6}{2}=3 \\
                  & \rightarrow 3,3 \\
  \end{align}
$$
By the way, all types of basic elementary operations (addition, subtraction, etc...) are allowed.
Question: Given any 4-digit number, how can I achieve a successful game?
Is this even possible?


text:
Q: 1D wave equation - solving a specific initial/boundary value problem I am trying to solve the following 1D wave equation problem with initial and boundary conditions.
$u_{tt} - c^2 u_{xx} = 0$
Initial and boundary conditions:
$u=f(x)\;, u_t=g(x) \;\;\; \text{for} \; t=0, x>0$
$u_t = \alpha u_x \;(\alpha \neq -c) \;\;\; \text{for} \; t>0, x=0$
I am also given that f and g are differentiable twice ($ \in C^2$) and that they vanish near x=0.
Here is what I have/know so far:
We know that u must be of the form:
$u = F(x+ct) + G(x-ct)$ where F and G are some functions 8we take that as a given ... it can be derived from e.g. characteristics). Taking that, we can conclude from the conditions above that:
$u_t(0,t) = cF'(ct)-cG'(ct) =\alpha(F'(ct) + G'(ct)) = \alpha u_x(0,t) \\
u(x,0) = F(x) + G(x) = f(x) \implies f'(x) = F'(x) + G'(x) \\
u_t(x,0) = cF'(x) - cG'(x) = g(x)$
I wrote those down because lines 2 and 3 are basic steps on the way to deriving d'Alembert's formula when we only have initial conditions at t=0 and solve in the upper xt - plane (i.e. for t > 0).
However, with this additional boundary condition, I am a bit lost ... I am lacking the idea of how to proceed and incorporate that bound condition.
Of course, I am not asking you to solve it for me, I would be happy about any hint/suggestion on how to proceed from here.
Thanks very much in advance!


text:
Q: Stop Excel from showing a graph value which is different from the data? My problem is that excel graphs are showing my data differently from the data that I'm using to plot it.
From the example below, the purple line Ebay/Play etc. is being plotted, but from point 28, the value is 1 but it is plotted around 180.

How do I stop Excel from showing a graph value which is different from the data?

A: Sorry folks seem to be having problem logging across from stackoverflow.
Many Thanks to Rene & Dav, for taking the time to look at my question.
Dav, your suggestion worked beautifully and was the cause of my problem. I've fixed it in the attached.
Rene, I of course checked to see the data was not out of range and you'll see from the original image that excel was showing the value as '1' but showing on the graph as 1500 ish


text:
Q: Using a built-in Sierra EM7455 mobile broadband I only get a local IP I'm on a Lenovo Thinkpad X1 Carbon (early 2016) that came with a built-in Sierra EM7455 card. I'd like to make the switch to Linux but I'm currently unable to make use of the mobile broadband connection.
In contrast to other questions asked regarding that piece of hardware, I have no trouble connecting via NetworkManager (using a live cd) - however, the interface never gets assigned a valid IP address, just a local address.
I'm using the German provider Congstar.
Any suggestions where to look or what I can do about this?

A: I have a 3rd gen X1 Carbon and WWAN(3G/LTE) works perfectly with 14.04. I actually work every day on LTE, as my company corporate network is very restricted. Modem is Sierra Wireless EM7345 4G LTE . I don't have a real solution for you, but 2 options to test come to my mind:

*

*try live CD with 14.04

*try dual boot with 16.04

If it works with 14.04 live CD - then there is an issue with 16.04. If it does not work, then try option 2).

A: First, test it in Windows if possible to make sure your SIM card actually is compatible with the laptop -- I've had compatibility issues before.
You need to pull in some packages from Yakkety Yak to Xenial -- specifically, libqmi 1.16.0, libmbim 1.14.0, and modemmanager 1.6.0. Upgrade those, reboot, and the modem should work. It does on mine. If you need more detailed instructions I'll provide them later when I'm not writing from my phone.
One caveat -- suspending and resuming the laptop kills the modem until your next reboot.
EDIT: If you're running a Yakkety live USB, then surprisingly the modem probably won't work, because the Yakkety kernel (4.4.0-9135) lacks a critical kernel patch that the EM7455 requires. The latest Xenial kernel (4.4.0-36) DOES have this patch, backported from mainline. You need to run Xenial and pull in the abovementioned Yakkety packages.

A: sorry for not getting back to this issue sooner but thanks for all the input (especially @djao and @Zlatko).
I have no problem connecting with the same SIM card using Windows 10. I have investigated this a bit further and apparently I can actually connect with a 16.04 LTS live CD just fine. At least there seems to be some kind of connection and I also get an IP address via DHCP as well as a gateway address but I am unable to connet to the outside world.
So on Linux I get this:
ifconfig:

enp0s31f6 Link encap:Ethernet  HWaddr 54:ee:75:98:13:6e
      UP BROADCAST MULTICAST  MTU:1500  Metric:1
      RX packets:0 errors:0 dropped:0 overruns:0 frame:0
      TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
      collisions:0 txqueuelen:1000
      RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
      Interrupt:16 Memory:f1200000-f1220000

lo    Link encap:Local Loopback
      inet addr:127.0.0.1  Mask:255.0.0.0
      inet6 addr: ::1/128 Scope:Host
      UP LOOPBACK RUNNING  MTU:65536  Metric:1
      RX packets:517 errors:0 dropped:0 overruns:0 frame:0
      TX packets:517 errors:0 dropped:0 overruns:0 carrier:0
      collisions:0 txqueuelen:1
      RX bytes:38626 (38.6 KB)  TX bytes:38626 (38.6 KB)

wlp4s0 Link encap:Ethernet  HWaddr 44:85:00:30:12:63
      UP BROADCAST MULTICAST  MTU:1500  Metric:1
      RX packets:0 errors:0 dropped:0 overruns:0 frame:0
      TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
      collisions:0 txqueuelen:1000
      RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

wwp0s20f0u2i12 Link encap:Ethernet  HWaddr 82:83:4b:ab:49:52
      inet addr:10.132.103.154  Bcast:10.132.103.155 Mask:255.255.255.252
      UP BROADCAST RUNNING NOARP MULTICAST  MTU:1500  Metric:1
      RX packets:0 errors:0 dropped:0 overruns:0 frame:0
      TX packets:51 errors:0 dropped:0 overruns:0 carrier:0
      collisions:0 txqueuelen:1000
      RX bytes:0 (0.0 B)  TX bytes:4303 (4.3 KB)

As you can see, I have an 10.x.x.x IP on the wwp0s20f0u2i12 device.
The routing table looks like this:
route -n:

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         10.132.103.153  0.0.0.0         UG    700    0        0 wwp0s20f0u2i12
10.132.103.152  0.0.0.0         255.255.255.252 U     700    0        0 wwp0s20f0u2i12
169.254.0.0     0.0.0.0         255.255.0.0     U     1000   0        0 wwp0s20f0u2i12

route -n:
Kernel IPv6 routing table
Destination                    Next Hop                   Flag Met Ref Use If
::/0                           ::                         !n   -1  1     1 lo
::1/128                        ::                         Un   0   3     4 lo
::/0                           ::                         !n   -1  1     1 lo

On Windows 10 the data looks like this (sorry, it's a German installation):
Windows-IP-Konfiguration

Ethernet-Adapter Ethernet:

   Medienstatus. . . . . . . . . . . : Medium getrennt
   Verbindungsspezifisches DNS-Suffix:

Drahtlos-LAN-Adapter LAN-Verbindung* 2:

   Medienstatus. . . . . . . . . . . : Medium getrennt
   Verbindungsspezifisches DNS-Suffix:

Mobiler Breitbandadapter Mobilfunk:

   Verbindungsspezifisches DNS-Suffix:
   IPv6-Adresse. . . . . . . . . . . : 2a01:598:80a0:ac2f:310f:dcc0:767e:79
   IPv6-Adresse. . . . . . . . . . . : 2a01:598:80a0:ac2f:6063:db5:32b:a774
   Temporäre IPv6-Adresse. . . . . . : 2a01:598:80a0:ac2f:d90:e51a:6ee4:1721
   Verbindungslokale IPv6-Adresse  . : fe80::310f:dcc0:767e:79%22
   IPv4-Adresse  . . . . . . . . . . : 10.120.86.84
   Subnetzmaske  . . . . . . . . . . : 255.255.255.248
   Standardgateway . . . . . . . . . : 2a01:598:80a0:ac2f:244e:b30a:d6e7:d2f5
                                   fe80::244e:b30a:d6e7:d2f5%22
                                   10.120.86.85

Ethernet-Adapter Bluetooth-Netzwerkverbindung:

   Medienstatus. . . . . . . . . . . : Medium getrennt
   Verbindungsspezifisches DNS-Suffix:

Drahtlos-LAN-Adapter WLAN:

   Medienstatus. . . . . . . . . . . : Medium getrennt
   Verbindungsspezifisches DNS-Suffix: fritz.box

Tunneladapter LAN-Verbindung* 13:

   Verbindungsspezifisches DNS-Suffix:
   IPv6-Adresse. . . . . . . . . . . : 2001:0:5ef5:79fd:1408:8b1f:af44:94a0
   Verbindungslokale IPv6-Adresse  . : fe80::1408:8b1f:af44:94a0%8
   Standardgateway . . . . . . . . . :

Tunneladapter isatap.{FD0ADE13-38D6-4003-88E7-7859324C8860}:

   Medienstatus. . . . . . . . . . . : Medium getrennt
   Verbindungsspezifisches DNS-Suffix:

And the routing table on Windows:
netstat -rn
===========================================================================
Schnittstellenliste
 17...54 ee 75 98 13 6e ......Intel(R) Ethernet Connection I219-V
 19...44 85 00 30 12 64 ......Microsoft Wi-Fi Direct Virtual Adapter
 22...98 85 9c 57 5a 5e ......Sierra Wireless EM7455 Qualcomm Snapdragon X7 LTE-A
  6...44 85 00 30 12 67 ......Bluetooth Device (Personal Area Network)
 21...3a f5 d1 8c 1b 5b ......Intel(R) Dual Band Wireless-AC 8260
  1...........................Software Loopback Interface 1
  8...00 00 00 00 00 00 00 e0 Microsoft Teredo Tunneling Adapter
 11...00 00 00 00 00 00 00 e0 Microsoft ISATAP Adapter #3
===========================================================================

IPv4-Routentabelle
===========================================================================
Aktive Routen:
     Netzwerkziel    Netzwerkmaske          Gateway    Schnittstelle Metrik
          0.0.0.0          0.0.0.0     10.120.86.85     10.120.86.84    311
     10.120.86.80  255.255.255.248   Auf Verbindung      10.120.86.84    311
     10.120.86.84  255.255.255.255   Auf Verbindung      10.120.86.84    311
     10.120.86.87  255.255.255.255   Auf Verbindung      10.120.86.84    311
        127.0.0.0        255.0.0.0   Auf Verbindung         127.0.0.1    331
        127.0.0.1  255.255.255.255   Auf Verbindung         127.0.0.1    331
  127.255.255.255  255.255.255.255   Auf Verbindung         127.0.0.1    331
        224.0.0.0        240.0.0.0   Auf Verbindung         127.0.0.1    331
        224.0.0.0        240.0.0.0   Auf Verbindung      10.120.86.84    311
  255.255.255.255  255.255.255.255   Auf Verbindung         127.0.0.1    331
  255.255.255.255  255.255.255.255   Auf Verbindung      10.120.86.84    311
===========================================================================
Ständige Routen:
  Keine

IPv6-Routentabelle
===========================================================================
Aktive Routen:
 If Metrik Netzwerkziel             Gateway
 22    311 ::/0                     2a01:598:80a0:ac2f:244e:b30a:d6e7:d2f5
 22    311 ::/0                     fe80::244e:b30a:d6e7:d2f5
  1    331 ::1/128                  Auf Verbindung
  8    331 2001::/32                Auf Verbindung
  8    331 2001:0:5ef5:79fd:1408:8b1f:af44:94a0/128
                                    Auf Verbindung
 22    311 2a01:598:80a0:ac2f::/64  Auf Verbindung
 22    311 2a01:598:80a0:ac2f:d90:e51a:6ee4:1721/128
                                    Auf Verbindung
 22    311 2a01:598:80a0:ac2f:310f:dcc0:767e:79/128
                                    Auf Verbindung
 22    311 2a01:598:80a0:ac2f:6063:db5:32b:a774/128
                                    Auf Verbindung
 22    311 fe80::/64                Auf Verbindung
  8    331 fe80::/64                Auf Verbindung
  8    331 fe80::1408:8b1f:af44:94a0/128
                                    Auf Verbindung
 22    311 fe80::310f:dcc0:767e:79/128
                                    Auf Verbindung
  1    331 ff00::/8                 Auf Verbindung
  8    331 ff00::/8                 Auf Verbindung
 22    311 ff00::/8                 Auf Verbindung
===========================================================================
Ständige Routen:
  Keine

So on Windows the IPv4 address is also from the 10.x.x.x range but I also get IPv6 addresses. Maybe this causes the issue on Linux since there is no IPv6 configuration setup (if I don't misread the linux output).
Any suggestions what might cause this or even better how to fix this? Thanks!


text:
Q: If $a^7 = b^7$ then $a = b$ How can I show using just the axioms of the integers that if $a^7 = b^7$, then $a=b$? It seems ridiculous but I cannot find the answer using just the axioms of order, equality etc.

A: Note that
$$ a^7 - b^7 = (a-b) \cdot \sum_{i=0}^6 a^{6-i}b^i $$
If the left hand side is zero, the right hand side must also be zero. But the sum is a sum of integers of the same sign.


text:
Q: apache2: host multiple sites under same domain in local server I've a local server with LAMP, ubuntu and apache2, and want to install several web applications (openproject, vtiger, suitecrm, sugar crm, ...) to test them. All them are web-based services.
I've unpacked them under /var/www and configured the virtual hosts as:
For Vtiger service: /etc/apache2/sites-available/vtigercrm.conf
<VirtualHost *:80>

#ServerName www.example.com

ServerAdmin angel@usmima.com
DocumentRoot /var/www/vtigercrm
ServerName vtigercrm
ServerAlias vtigercrm.serverMachine.synology.me
Alias /vtigercrm /var/www/vtigercrm

ErrorLog ${APACHE_LOG_DIR}/vtigercrm-error.log
CustomLog ${APACHE_LOG_DIR}/vtigercrm-access.log combined
</VirtualHost>

For Suite crm service: /etc/apache2/sites-available/suitecrm.conf
<VirtualHost *:80>

ServerAdmin angel@usmima.com
DocumentRoot /var/www/suitecrm
ServerName suitecrm
ServerAlias suitecrm.serverMachine.synology.me
ServerAlias localhost
Alias /suitecrm /var/www/suitecrm

ErrorLog ${APACHE_LOG_DIR}/suitecrm-error.log
CustomLog ${APACHE_LOG_DIR}/suitecrm-access.log combined

   <Directory /var/www/suitecrm/>
        Options Indexes FollowSymLinks
        AllowOverride All
        Require all granted
   </Directory>
</VirtualHost>

And for openproject: /etc/apache2/sites-available/openproject.conf
Include /etc/openproject/addons/apache2/includes/server/*.conf

<VirtualHost *:80>
  ServerName openproject
  ServerAlias serverMachine.synology.me
  ServerAlias localhost
  DocumentRoot /opt/openproject/public

  ProxyRequests off

  Include /etc/openproject/addons/apache2/includes/vhost/*.conf

  ProxyPass /openproject/ http://127.0.0.1:6000/openproject/ retry=0
  ProxyPassReverse /openproject/ http://127.0.0.1:6000/openproject/
</VirtualHost>

I can access to each one of the services with their ServerAlias addresses:

*

*vtigercrm.serverMachine.synology.me

*suitecrm.serverMachine.synology.me

*serverMachine.synology.me/openproject

but if I want to access them locally, http://localhost/openproject is the only one working. http://localhost/suitecrm or http://localhost/vtigercrm do not work.
How do I have to configure so I can access to each service as accessing to the different folders of the same domain? For instance:

*

*http://localhost/suitecrm      or     http://192.168.1.123/suitecrm

*http://localhost/vtigercrm      or     http://192.168.1.123/vtigercrm
The case for openproject is working:

*

*http://localhost/openproject    or  http://192.168.1.123/openproject
Thanks
EDIT 1
I've managed to half solve the problem editing the virtual host configuration for openproject adding:
Alias /vtigercrm /var/www/vtigercrm
Alias /suitecrm  /var/www/suitecrm

Which seems to indicate that openproject is being launched when accessing. What do I have to do to avoid needing openproject virtual host to properly route access to vtiger, suitecrm and other sites?
Thanks

A: I'd suggest changing your system's hosts file.
In /etc/hosts
replace
127.0.0.1 localhost

with
127.0.0.1 serverMachine.synology.me vtigercrm.serverMachine.synology.me suitecrm.serverMachine.synology.me localhost

Now simply type in the same address you would if you were on another system - the browser will send exactly the same information as it would for an external user, so Apache will respond in the same way.


text:
Q: Building custom python packages in BAZEL I have a beam pipeline very similar to the juliaset with the same folder strutcutre and setup.py. How do I build this in bazel? It seems like it should be as easy defining a py_library that has the local requirement of the local package but I cannot make it work? Any help / examples are greatly appreciated.
py_library(
    name = "lib",
    srcs = ["**/*.py"],
    imports = ["."]
    srcs_version = "PY3",
    visibility = ["//visibility:public"],
    deps = [//path/to/juliaset/setup.py],
)


text:
Q: Python - Best way to use several tuple values in a for loop Is there a better, more efficient way to use several tuple values in a for loop? For example, I have a list of tuples I am iterating through and each one of those tuples has several values:
values = [(a,b,c,d,e,f,g,h,i,j), (a,b,c,d,e,f,g,h,i,j)]

for a,b,c,d,e,f,g,h,i,j in values:
    do this......

Is there a more efficient, pythonic way to do handle a task like this without using so many iterators? I am still a bit new to Python (and coding in general). Thanks.

A: Depends on what you are trying to do, but I would:
for value in values:
    do this.....
    #refer to each element as value[0], value[1]...


text:
Q: Android camera image orientation How can we get the image in correct orientation? ExifInterface always returns 0. I tried using EasyImage (https://github.com/jkwiecien/EasyImage), however it produces the same results.
I tried every single suggestion from this thread without any luck: Why does an image captured using camera intent gets rotated on some devices on Android?
In Android 7 emulator I observe the following behaviour: once you take the image, it rotates 90 degrees while you are still in the camera - even before you accept the image.
What am I missing?
Here is what happens in the emulator and on Note 4:
1) White taking the picture:

2) Right after taking the picture, before even accepting it and before the application is even aware of any images and their orientation - you see it rotated:


text:
Q: finding the decomposition of Laplacian matrix with position of zero elements unchanged I'd like to know whether it's possible to find the decomposition of a Lapalacian matrix $A$
$B^TB = A$
where $B$ has the same dimension with $A$ and the position of zero elements in $B$ is the same with that in $A$ or slightly changed.


text:
Q: Coney and rabbit: what's the difference? Are the words coney and rabbit full synonyms in English? Are there any slight differences in usage or meaning? Are there any cases when one word is more appropriate in the modern writing or speech than another one?
Merriam-Webster and Wiktionary reference coney as a rabbit (especially, the European rabbit) without additional remarks. The OED does the same, but with a note British & Heraldry.

A: I've only heard the word coney in one context:

I've treacle and toffee, I've tea and I've coffee,
  Soft tommy and succulent chops;
  I've chickens and conies, and pretty polonies,
  And excellent peppermint drops.
(from Little Buttercup's Song, HMS Pinafore, Gilbert and Sullivan)

In that usage, it's a full synonym. From the Online Etymology Dictionary:

Rabbit arose 14c. to mean the young of the species, but gradually pushed out the older  word 19c., after British slang picked up coney as a punning synonym for cunny "cunt". The word was in the King James Bible, however, so it couldn't be entirely dropped, and the solution was to change the pronunciation of the original short vowel (rhyming with honey, money) to rhyme with boney.

So, yes, it's a full synonym, but out of use these days, unless you're into musicals.

A: I've never heard the word coney before.
The OED has five sub-definitions for coney meaning rabbit. The first four the most recent citations in the late 19th century, and the fifth in the 16th century:

a. A rabbit: formerly the proper and ordinary name, but now superseded in general use by rabbit, which was originally a name for the young only.
b. Still retained in the Statutes, and in more or less familiar use with game-keepers, poachers, game-dealers and cooks: in market reports, now usually meaning a wild rabbit.
c. It is also the name in Heraldry.
d. dial. In some districts applied to a young rabbit, but elsewhere more properly to an old one.
e. (without pl.). The flesh of the rabbit.

Other definitions of coney or cony are for rabbit fur, a number of other small animals, a term of endearment, and a kind of shell-fish.
Therefore, unless you're going to use coney in a very specific context where it has a special meaning for your audience, you're better off using the much more well-known rabbit.

A: Unfortunately, its been a long time since I last read Enid Blyton; but I recall coming across 'coney' in some Famous Five books.
IIRC it wasn't used as an exact synonym for rabbit; the impression I got was a local smaller variety of rabbit (something like a country mouse instead of a city mouse e.g.)

A: In most (if not all) of the USA, coney is a word for a smallish hotdog.

The first time I heard it used in a context that clearly called for a game animal, you can imagine how confused I was.
The animal here is referred to only as a Rabbit or a Bunny (sometimes Bunny-Rabbit). I almost never hear "hare" used, unless somebody is trying to make a pun of some kind. I have never heard "coney" used to refer to the animal in conversation. Only in literature.

A: The 'Journal of Thomas Dineley' on his tour of Co. Clare, Ireland in 1681 — "Cony Island took its name from the great number of Rabbits and Coneys there..."— seems to suggest, at that time, coneys were distinct from rabbits. Maybe hares?

A: Of Leporids and Country Matters
Rabbit or hare, and familiarly bunny, are now the common words for the critters once commonly called coney.  The OED reports that coney is now in "more or less familiar use with game-keepers, poachers, game-dealers and cooks".  J.R.R. Tolkien alluded to this in The Hobbit, for
as all readers of  Tolkien know, a coney is just an older name for a rabbit, as Bilbo observes when interrogating Gandalf about Beorn the skin-changer, and which Sam later cooks up in a stew:

*

*'What! a furrier, a man that calls rabbits conies, when he doesn't turn their skins into squirrels?' asked Bilbo.

*Our bread chokes you, and raw coney chokes me.

*If you give me a coney, the coney's mine, see, to cook, if I have a mind.

*Sam busied himself with his pans. 'What a hobbit needs with coney,' he said to himself, 'is some herbs and roots, especially taters – not to mention bread.
There's some left, if you want to try stewed coney.'

*We shall have it like a coney in a trap.

*But now he has done worse trespass than only to go coney-snaring in the uplands: he has dared to come to Henneth Annyn, and his life is forfeit.

Rabbits are something of an anachronism in Tolkien's legendarium, not being native to the historical region he was depicting, so he usually chose an older word to describe them.  Our word rabbit originally meant only the young, not the full-grown version, for which coney was reserved. The OED tells an interesting tale for the word coney:

*

*

*

*a. A rabbit: formerly the proper and ordinary name, but now superseded in general use by rabbit, which was originally a name for the young only.

*b. Still retained in the Statutes, and in more or less familiar use with game-keepers, poachers, game-dealers and cooks: in market reports, now usually meaning a wild rabbit.

*c. It is also the name in Heraldry.

*d. dial. In some districts applied to a young rabbit, but elsewhere more properly to an old one.

*e. (without pl.). The flesh of the rabbit.

*
*

*a. The skin or fur of the rabbit. (The earliest recorded use in Eng.) Obs. or dial.

*b. A hat made of rabbit-fur (in place of beaver). U.S.

*In O.T. used to translate Hebrew shāphān, a small pachyderm (Hyrax Syriacus), living in caves and clefts of the rocks in Palestine.

*Applied also locally to the Cape Hyrax or Das (Hyrax Capensis), and to the Pika or Calling Hare (Lagomys princeps) of the Rocky Mountains; also with qualifications to other small quadrupeds.

*
*

*† a. A term of endearment for a woman. Obs.

*b. Also indecently.

*† A dupe, a gull; the victim of the 'cony-catcher'. Obs.

*
*

*a. Some kind of shell-fish; ? a cone.

*b. A name for the Nigger-fish (Epinephelus punctatus) of the West Indies.

As you see by sense 5b, it turns out that coney used to rhyme with honey and money, but this was just too punny for its own good.  One of the citations for sense 5b:

*

*1622 Massinger Virg. Mart. ɪɪ. i ―A pox on your Christian cockatrices! They cry, like poulterers' wives, 'No money, no coney'.

So why do we today rhyme coney with bony instead of with bunny as we once did?  Too many uncunning punsters, basically, giving it a vulgar sense. Shakespeare himself did this, as shown later in this posting.
Here the OED's etymology for coney:

The current form represents OFr. conil, connil, cogn. w. Pr. conil, Sp. conejo, Pg. coelho, Ital. coneglio:-L. cunīcul-us rabbit (also burrow, underground passage, military mine), according to ancient authors a word of Spanish origin. The OFr. pl. (with l suppressed) coniz, later conis, gave an Eng. pl. conys, conies, and this a singular cony, conie. The ME. cunin, konyne, conyng was a. OFr. conin, connin, Anglo-Fr. coning, a parallel form to conil, which gave also MDutch conijn, Dutch konijn, and, with a for o, LG. kanîn, whence mod.G. dim. kaninchen. In Eng. the form cunyng, cunning came down to the 16th c.; but from the 12th c. onward it varied also with cunig, conig, connyg.
The historical pronunciation is with /ʌ/; common spellings from 16th to 18th c. were cunnie, cunney, cunny, and the word regularly rimed with honey, money, as indicated also by the spelling coney; but during the 19th c. the pronunciation with long ō has gradually crept in. This pronunciation is largely due to the obsolescence of the word in general use, while it occurred in the Bible, and esp. in the Psalms, as the name of a foreign animal (sense 3); the oral tradition being broken, readers guessed at the word from the spelling. It is possible, however, that the desire to avoid certain vulgar associations with the word in the cunny form, may have contributed to the preference for a different pronunciation in reading the Scriptures. Walker knew only the cunny pronunciation; Smart (1836) says 'it is familiarly pronounced cunny', but cōny is 'proper for solemn reading'. The obsolescence of the word is also a cause of the unfixed spelling; the Bible of 1611 has conie, cony, conies, modern editions coney, conies (cf. money, monies), an irregularity retained in the Revision of 1885.
The rabbit is evidently of late introduction into Britain and Northern Europe: it has no native name in Celtic or Teutonic, and there is no mention of it in England before the Norman period; in the quotations the fur, perhaps imported, appears before the animal. The Welsh cwning, cwningen, is from ME.; the Irish coinnín, and Gaelic coinean, coinein from ME. or AFr.

About the time that coney was getting bad press for its punny association with cunny, the word bunny appeared as a more clean-minded but still rhyming synonyn for the rabbit version, making it something of a minced oath.  But the pun was already there in the original Latin cuniculus, so it's been with us for a long time.
In As You Like It, Shakespeare has Rosalind liken herself to a coney when she's speaking to Orlando "like a saucy lackey, and under that habit play the knave with him":

Orlando. Where dwell you, pretty youth?
Rosalind. With this shepherdess, my sister; here in the skirts of
  the forest, like fringe upon a petticoat.
Orlando. Are you native of this place?
Rosalind. As the coney that you see dwell where she is kindled.
Orlando. Your accent is something finer than you could purchase in
  so removed a dwelling.

Notice it's a decidedly female coney that Rosalind mentions. Shakespeare is being naughty there — or saucy, as he himself put it.  Under the historical pronunciation /ʌ/ used in Shakespeare's thyme, the actor speaking that like would have rhymed coney with honey, and audiences of that age all would have got the joke, just as they did when Shakespeare elsewhere wrote of "country matters".  Without the necessary rhyme, the intended sauciness may well be lost on latterday audiences.
Rabbits and hares are in the Leporid family, which along with rock coneys, make up the Lagomorph order.  Rock coneys are a local name for the pika, as OED sense 4 explains.  However, it now goes by a different genus: it's actually  Ochotona princeps.  But it's still a coney, even though it isn't a rabbit or a hare.  Sometimes people even call it a whistling hare — not that it is a hare, mind you.  Regular folks are very particular about common names for things, you see.
So coney is a sort of older, local, or rustic name for any leporid or even lagomorph, one perhaps still favored by Bilbo's furriers.
Another place you might come across coney is in the dialect word to coney-fogle, also spelled connyfogle. It means to ingratiate oneself, to cheat by bewildering.  [Sources: the English Dialect Dictionary, and also Provincial Words and Expressions Current in Lincolnshire (1866).] This is probably related to the OED's sense 6 of being a dupe, not to its leporid sense 1, although coney-fogle does sound rather vulgar if you're a punny-bunny about both halves of the compound.
Coney-fogle may have given rise to the later U.S. colloquialism to honey-fuggle, again meaning to dupe, deceive, or swindle, but not quite so vulgarly.  Still seems a bit naughty, though, especially if you haven't heard it before.


text:
Q: JFET question about operation I have a question about the N-JFET.Assume it operates at the linear region and it acts like a voltage controlled resistor. Can we say that if Vdg(drain-gate voltage) is increased then the resistance of the JFET is increased?I have just started reading about JFET and I find them very confusing.
Also I found this video , I don't understand why most have Vds and Vgs which is very confusing...


text:
Q: React - Key down event first triggers on body then on element I'm injecting some code which creates a text input into existing pages on the internet.
On some sites, when the user presses some specific keys while focused onto my text input, the event gets captured instead of being bubbled.
I've been trying multiple solutions to prevent this but they do not seem to work:
  keyUp = event => {
    event.preventDefault();
    event.nativeEvent.stopImmediatePropagation();
    event.stopPropagation();
    return false;
  };

<Form.Control
            as="textarea"
            onChange={this.updateInput}
            onKeyUp={this.keyUp}
            onKeyPress={this.keyUp}
            onKeyDown={this.keyUp}
          />

Is there a way I can prevent this event from being triggered on the body instead of being triggered in my element first?

A: React attaches its event listener to body by default, and uses that to trigger its own SyntheticEvent
You could try attaching your event in capture mode by appending Capture to your event name, as outlined here
Edit (added for clarification to comment):
Attach an event to your window:
window.addEventListener("keydown", function (evt) {
  if (evt.target.id === 'elementID') {
    //do what you want to, here.
    //if you want to prevent the event propagating:
    evt.stopImmediatePropagation();
    evt.stopPropagation();
  }
}, true);

in your jsx:
...
<input id='elementID' />
...

A: I've added a listener at window level to capture the event and prevent propagation down. Of course if a listener is already added at window level this will not work:
window.addEventListener("keydown", this.keyDown, true);


text:
Q: windows - desired state configuration I applied a DSC Configuration and it was successful applied through both the commands, either by using
start-dscconfiguration -wait -force -path <Path of the folder containing MOF file>

or
$paramforSendConfigurationApplyMethod = @{
ConfigurationData = $dataInUint8Format
force = $True
}
Invoke-CimMethod -CimClass $cimClass -CimSession $wsmanSession -MethodName SendConfigurationApply -Arguments $paramforSendConfigurationApplyMethod -Verbose

When I tried to test the configuration , with the below command Test-DscConfiguration -ReferenceConfiguration <Path of localhost.mof> , the output I got is

InDesiredState : True ResourcesInDesiredState :
{[RegistryPolicyFile]Registry(POL):
HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\Ext\RunThisTimeEnabled,
[RefreshRegistryPolicy]ActivateClientSideExtension}
ResourcesNotInDesiredState : ReturnValue : 0 PSComputerName :
Localhost

However, when I tried to execute the Test configuration with the CIM method
$paramforTestConfiguration = @{
ConfigurationData = $dataInUint8Format
}
invoke-CimMethod -CimClass $cimClass -CimSession $wsmanSession -MethodName TestConfiguration -Arguments $paramforTestConfiguration | format-list

, I got the results as null

InDesiredState : False ResourcesInDesiredState :
ResourcesNotInDesiredState : ReturnValue : 0 PSComputerName :
localhost

I am not sure why for the same DSC configuration, both "Test" commands are displaying different output.i.e., one output says that the DSC is in Desired state but the other is not.
I am testing this in the local stand alone development windows computer (ws2019)


text:
Q: how run a unity project in flutter I try to add my simple unity project to flutter but after build-in console I got an Error:
Lost connection to the device.

top of consol in vsCode I get these Error with red colour:
Note: C:\Fproject\unity_flutter\android\UnityExport\src\main\java\com\unity3d\player\UnityPlayerActivity.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: C:\src\flutter\.pub-cache\hosted\pub.dartlang.org\flutter_unity_widget-0.1.6+8\android\src\main\java\com\rexraphael\flutterunitywidget\FlutterUnityViewFactory.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.

what should I do?? please help
Thanks a lot.

A: After the result you saw, I believe answering your question would help a lot of people who will just start off with this.
The solution is to use your real device and run the project using flutter run.
Why success in real device and failure in emulator?

Many a times, an emulator doesn't supports some functionalities. The real device has a perfect engine to support all of them, hence you get the problem sorted.

To Build apk

flutter build apk --release

Consider reading upon this documentation: Build and release an Android app


text:
Q: Scrollbar is offsetted Here is a very simple demo to show what I mean.
<!doctype html>

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis magna purus, tincidunt nec dapibus nec, faucibus eu lorem. Integer viverra ultrices diam eget interdum. Nam volutpat dolor a nisi suscipit molestie. Suspendisse molestie mauris at tellus ornare id ultricies lectus varius. Proin nisl diam, egestas in malesuada tincidunt, egestas eu libero. Suspendisse pretium elementum facilisis. Mauris volutpat scelerisque odio, non egestas velit malesuada a. Quisque dictum nibh eget ipsum pretium nec luctus est pulvinar. In hac habitasse platea dictumst. Donec eget purus sit amet diam sodales ultricies. Aliquam erat volutpat. Proin nulla libero, dictum eu fermentum et, egestas ut lacus. Nunc gravida ligula ac velit bibendum vel luctus neque eleifend. Praesent aliquet tempus felis eget commodo.

As you can see the scrollbar continues past the bottom of the browser window. It does that with the same amount as as the #top divider's height. Also if you shrink the browser window, you must pass the bottom line with the #top height before the scrollbar appears.
It is like the scrollbar is offsetting the browser's top instead of the #doc top.
It is the same result in IE9, FireFox and Chrome.
Any clue of how to fix this?

A: Thats is because
#doc { height: 100%; }

take the same height of  body & html (100%) but the #top subtracts 100px
Example: http://jsfiddle.net/GaVgV/1/
If you need maintain the top in 100px, then you need use jQuery to calculate the height free.
$('#doc').height($('body').height() - $('#top').height())

Example: http://jsfiddle.net/GaVgV/4/


text:
Q: Обратная польская запись для Pascal-выражений void semantic::create_reverse_polish() {
    reverse_polish_out.clear();
    while (!reverse_polish_stack.empty())
        reverse_polish_stack.pop();

    while (!reverse_polish_in.empty()) {
        const csymbol sym = reverse_polish_in.front();
        reverse_polish_in.erase(reverse_polish_in.begin());
        // Если символ является константой или переменной, добавляем его к выходной строке
        if (sym.type == st_const || ident_table[sym.ident].value.type == ct_integer || ident_table[sym.ident].value.type == ct_real || ident_table[sym.ident].value.type == ct_char || ident_table[sym.ident].value.type == ct_boolean) {
            reverse_polish_out.push_back(sym);
            may_be_unary = false;
        }
            // Если символ является открывающей скобкой, помещаем его в стек
        else if (sym.op == op_l_bracket) {
            reverse_polish_stack.push(sym);
            may_be_unary = true;
        }
            // Если символ является закрывающей скобкой
        else if (sym.op == op_r_bracket) {
            may_be_unary = false;
            // До тех пор, пока верхним элементом стека не станет открывающая скобка, выталкиваем элементы из стека в выходную строку. При этом открывающая скобка удаляется из стека, но в выходную строку не добавляется
            while (!reverse_polish_stack.empty() && reverse_polish_stack.top().op != op_l_bracket) {
                reverse_polish_out.push_back(reverse_polish_stack.top());
                reverse_polish_stack.pop();
            }
            if (!reverse_polish_stack.empty())
                reverse_polish_stack.pop();
        }
            // Если символ является оператором о1, тогда:
        else if (reverse_polish_is_kw_or_op(sym)) {
            if (sym.op != op_sub && sym.op != op_add && sym.kw != kw_not)
                may_be_unary = sym.op == op_equal || sym.op == op_not_equal || sym.op == op_less || sym.op == op_greater || sym.op == op_less_or_equal || sym.op == op_greater_or_equal;

            // пока (если оператор o1 право-ассоциированный) приоритет o1 меньше приоритета оператора, находящегося на вершине стека
            if (may_be_unary && (sym.op == op_add || sym.op == op_sub || sym.kw == kw_not))
                while (!reverse_polish_stack.empty() && reverse_polish_stack.top().op != op_l_bracket && operators_priorities[sym.type == st_op ? sym.op : sym.kw] > operators_priorities[reverse_polish_stack.top().type == st_op ? reverse_polish_stack.top().op : reverse_polish_stack.top().kw]) {
                    if (reverse_polish_stack.top().op != op_l_bracket)
                        reverse_polish_out.push_back(reverse_polish_stack.top());
                    reverse_polish_stack.pop();
                }
            else
                // пока (если оператор o1 ассоциированный, либо лево-ассоциированный) приоритет o1 меньше либо равен приоритету оператора, находящегося на вершине
                while (!reverse_polish_stack.empty() && reverse_polish_stack.top().op != op_l_bracket && operators_priorities[sym.type == st_op ? sym.op : sym.kw] >= operators_priorities[reverse_polish_stack.top().type == st_op ? reverse_polish_stack.top().op : reverse_polish_stack.top().kw]) {
                    if (reverse_polish_stack.top().op != op_l_bracket)
                        reverse_polish_out.push_back(reverse_polish_stack.top());
                    reverse_polish_stack.pop();
                }

            if (may_be_unary && sym.op == op_sub)
                reverse_polish_stack.push(csymbol(st_op, op_unary_minus));
            else if (may_be_unary && sym.op == op_add)
                reverse_polish_stack.push(csymbol(st_op, op_unary_plus));
            else
                reverse_polish_stack.push(sym);
        }
    }
    while (!reverse_polish_stack.empty()) {
        reverse_polish_out.push_back(reverse_polish_stack.top());
        reverse_polish_stack.pop();
    }
}

На вход функции подается инфиксная запись выражения. Дело в том, что выражения, в которых содержится not, обрабатываются неправильно. Например, для выражения not a + b <= -4 на выходе должно быть a b + 4 - <= not, а получается a not b + 4 - <=, то есть как будто not применяется для a, а не для всего выражения.
Приоритет операций (другие операции содержаться в выражении не могут):
unordered_map<int, int> semantic::operators_priorities = {
    {kw_not, 1}, {op_unary_plus, 1}, {op_unary_minus, 1},
    {op_mul, 2}, {op_div, 2}, {kw_div, 2}, {kw_mod, 2}, {kw_and, 2},
    {op_add, 3}, {op_sub, 3}, {kw_or, 3},
    {op_equal, 4}, {op_less, 4}, {op_greater, 4}, {op_not_equal, 4}, {op_less_or_equal, 4}, {op_greater_or_equal, 4}
};


text:
Q: equation with exponential functions 3
Solve the following equation over the real numbers(without utilising calculus)
  $$ (\frac{1}{2})^{1+x}+(\frac{1}{6})^{x}-\sqrt{2}\cdot(\frac {\sqrt{2}}{6})^x=1 $$

I simply can't really find a solid starting point; I thinks it might be a notation tham I'm oblivious to; I do know the root of the equation $ x=-1 $ thanks to Wolfram, but am interested more in the steps to determine it.

A: To get rid of all the fractions, set $y=-x$ to get
$$2^{y-1}+6^y-\sqrt{2}(3\sqrt{2})^y=1,$$
from which it is quickly clear that $y=1$ is a solution. Moreover, rearranging shows that
$$1-2^{y-1}=6^y-\sqrt{2}(3\sqrt{2})^y=3^y(2^y-\sqrt{2}^{y+1})\tag{1},$$
and if $y\neq1$ then $2^y-\sqrt{2}^{y+1}\neq0$ and so we find that
$$3^y=\frac{1-2^{y-1}}{2^y-\sqrt{2}^{y+1}}=-\frac{1}{2}-\sqrt{2}^{-y-1},$$
where the left hand side is positive and the right hand side is negative, a contradiction. Hence there is no solution with $y\neq1$, i.e. the unique solution is $y=1$.

A: Hint:
First rewrite as:
$$
\frac{1}{2}\left(\frac{1}{2}\right)^{x}+\left(\frac{1}{6}\right)^{x}-\sqrt{2}\cdot\left(\frac {\sqrt{2}}{6}\right)^x=1
$$
Now the idea is to replace the exponentials with other variables:
$$
y=\left(\frac {1}{\sqrt{2}}\right)^x
$$
$$
z=\left(\frac {1}{3}\right)^x
$$
Then:
$$
\frac{1}{2} y^2+y^2 z-\sqrt{2} yz=1
$$

A: We need to solve that
$$\frac{3^{x}}{2}+1-(\sqrt2)^{x+1}=6^x$$ or
$$3^x\left(2^x-\frac{1}{2}\right)+(\sqrt2)^{x+1}-1=0$$ or
$$3^x\left((\sqrt2)^{x+1}-1\right)\left((\sqrt2)^{x+1}+1\right)+2\left((\sqrt2)^{x+1}-1\right)=0$$ or
$$\left((\sqrt2)^{x+1}-1\right)\left(3^x\left((\sqrt2)^{x+1}+1\right)+2\right)=0$$ or
$$(\sqrt2)^{x+1}=1,$$ which gives $x=-1.$


text:
Q: C# convert JSON result I am getting this JSON back from Box.com:
{
    "total_count": 2,
    "entries": [
        {
            "type": "file",
            "id": "2615240421",
            "sequence_id": "0",
            "name": "successful file upload.png",
            "description": null,
            "size": 19586,
            "path": "/Hey Hey Whats Goin On/successful file upload.png",
            "path_id": "/316877053/2615240421",
            "created_at": "2012-07-11T11:54:21-07:00",
            "modified_at": "2012-07-11T11:54:21-07:00",
            "etag": null,
            "created_by": {
                "type": "user",
                "id": "181757341",
                "name": "sean test",
                "login": "sean+test@box.com"
            },
            "modified_by": {
                "type": "user",
                "id": "181757341",
                "name": "sean test",
                "login": "sean+test@box.com"
            },
            "owned_by": {
                "type": "user",
                "id": "181757341",
                "name": "sean test",
                "login": "sean+test@box.com"
            },
            "shared_link": null,
            "parent": {
                "type": "folder",
                "id": "316877053",
                "sequence_id": "0",
                "name": "Hey Hey Whats Goin On"
            }
        },
        {
            "type": "file",
            "id": "2615240431",
            "sequence_id": "0",
            "name": "a whole lot of shit just happenedjson.png",
            "description": null,
            "size": 128063,
            "path": "/Hey Hey Whats Goin On/a whole lot of shit just happenedjson.png",
            "path_id": "/316877053/2615240431",
            "created_at": "2012-07-11T11:54:21-07:00",
            "modified_at": "2012-07-11T11:54:21-07:00",
            "sha1": null,
            "created_by": {
                "type": "user",
                "id": "181757341",
                "name": "sean test",
                "login": "sean+test@box.com"
            },
            "modified_by": {
                "type": "user",
                "id": "181757341",
                "name": "sean test",
                "login": "sean+test@box.com"
            },
            "owned_by": {
                "type": "user",
                "id": "181757341",
                "name": "sean test",
                "login": "sean+test@box.com"
            },
            "shared_link": null,
            "parent": {
                "type": "folder",
                "id": "316877053",
                "sequence_id": "0",
                "name": "Hey Hey Whats Goin On"
            }
        }
    ]
}

I need to get the Modified information for each file.  Not sure how to do this in .NET.  I'm used to parsing XML.  I've seen a few examples on Stack, but they are usually shallow objects.  Not sure about deeper objects.
Help?
Thanks

A: I would just use the built in JavaScriptSerializer class. You can deserialize your JSON to a specific type or an 'on-the-fly' type which you can then 'traverse'.


text:
Q: Open URLs in Google Chrome and resize windows I've got a few monitoring sites set up for my mobile apps (e.g. crittercism) and I have an extra monitor set up for monitoring everything.  I have a few Chrome windows sized down to just the values I'm interested in and spaced so that everything fits on the screen.
I'd like to write a macro that launches all (at this point 8 sites) these Chrome/browser windows and spaces them accordingly.
Rebooting and resizing right now is a pain.

A: Probably you're interested in open. So you could open /Applications/Google\ Chrome.app or you could similarly open http://www.google.com. You can also use AppleScript to position windows automatically, including directly from the command line via osascript — see e.g. this answer on the Linux & Unix StackExchange.

A: You can use JavaScript. Save the following code as a .html file:
<html>
<script>
function openWindows() {
  window1=window.open('http://google.com/','','width=400,height=300');
  window1.moveTo(0, 0);
  window2=window.open('http://yahoo.com/','','width=400,height=200');
  window2.moveTo(0, 300);
  window3=window.open('about:blank','','width=200,height=500');
  window3.moveTo(400, 0);
};
</script>
<button onclick="openWindows();">Open Windows</button>
</html>

Open it in your browser and click the button. You should see something like this:

NB: You'll probably have to relax your popup blocker settings. Here's how to change the popup settings on Chrome:

This won't change popup blocker settings for other websites.

On Mac, an extra monitor extends the screen size. For example, if your secondary monitor is arranged to the left of the primary monitor, window4.moveTo(-300, 0); should do the trick.


text:
Q: React-Leaflet adding sign on center of map I add a sign on map that shows the center.
<MapContainer fullscreenControl={true}
                    center={center} zoom={18}
                    maxNativeZoom = {22}
                    maxZoom={22}
                    className={"sign-of-center-of-map"}>

.sign-of-center-of-map:before {
    position: absolute;
    content: "\271B";
    z-index: 800;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    font-size: 3rem;
    opacity: 0.7;
}

But when i do that, layers on the map become non-clickable. I changed z-index of layers but this didn't solve the issue. Should i add something to CSS or use different method?

A: You should use a better method to reach this feature, React-leaflet has Control feature that you can add whatever you want to your map
For Example:
import L from "leaflet";

createDivControl() {
const MapHelp = L.Control.extend({
  onAdd: (map) => {
    const signOfCenterOfMap = L.DomUtil.create("div", "");
    this.signOfCenterOfMap = signOfCenterOfMap;
    // set the inner content from the props
    signOfCenterOfMap.innerHTML = this.props.title; // it can be your icon

    // return the div
    return signOfCenterOfMap;
  }
});
return new MapHelp({ position: "bottomright" })} // 'bottomleft','bottomright', ...

In this example, you must set the position of your div


text:
Q: Transistors replacement Can I safely replace 2N3904 and 2N3906 with BC337 and BC327 in an audio amplifier circuit since both pairs are NPN, PNP?

simulate this circuit – Schematic created using CircuitLab

A: I wanted to add a few thoughts about your schematic, itself, as well. There are a few questions and problems that I see (as a hobbyist.)

*

*You don't specify what your input signal looks like. Without that information it is difficult to say much at all about the circuit. The gain shown is about \$100\times\$, which may be too high, too low, or just right. No way to tell. But for now, let's assume it is just right and move on.

*Assuming you really do need that gain and that the BJTs are driving close to the rails (let's say no closer than \$1V\$, though, so that they stay out of saturation), they each will be delivering about \$P_{load}=\frac{V_{peak}^2=5V^2}{2\cdot 8\Omega}\approx 1.5 W\$ into the load speaker. Since optimal delivery of power into a load requires a source impedance that is about the same, an efficient linear amplifier design can at best hope to deliver \$1.5 W\$ by itself dissipating the same amount. So each of your output BJTs will be picking up at least \$P_{bjt}=\frac{1}{2}\cdot 1.5W = 750mW\$. This will require packaging that is NOT a TO-92, but instead a TO-220 style.

*Each BJT might be expected to supply \$I_{C_{peak}}=\frac{V_{peak}=5V}{8\Omega}=625mA\$. You also need to make sure that the selected BJTs are specified to supply \$I_C\ge 1A\$. \$I_C=2A\$ would be even better to see on the datasheet.

*The base current for each BJT will be, because they are staying out of saturation (per my earlier estimation above), on the order of a factor of \$\beta \ge 50\$ lower. So you must expect that the opamp itself can supply at least \$20mA\$ at its output, just to be safe. The LM741 has a short-circuit output of about \$25mA\$. So you are near the margins here. But I think it will be okay because although I estimated \$\beta \approx 50\$ here, you may get as much as \$3-5\times\$ better than that depending on the output BJT and its operating point. So let's assume it is okay for now.

*The LM741 also has a problem reaching its rails. Let's say your LM741 is required to supply \$I_{peak}=10mA\$ to your BJTs. Assuming it can reach to the rails (it cannot even come close to that), this implies an effective load of about \$\frac{6V}{10mA}=600\Omega\$. However, the datasheet says that even with a lighter load of only \$2k\Omega\$ the best you can be absolutely sure of is that it can come within about \$5V\$ of a \$15V\$ rail, or about \$10V\$. They do say that it typically can get closer -- perhaps within \$2V\$ of the rails. But no matter how you look at it, this opamp isn't going to come close to your rails. So this means you cannot expect to see even \$V_{peak}=5V\$ on your speakers. If we go with a drop of \$3V\$ at the opamp output, plus another diode drop for the BJT emitter, you are looking at a maximum \$V_{peak}=2V\$ or so. This suggests only \$\frac{1}{4}W\$ of output. And an even smaller input signal acceptance, given the gain programmed into your circuit. On the good side, this means that your BJTs could just be TO-92 packaged parts and you can use small signal devices there (assuming they can still provide \$\frac{2V}{8\Omega} = 250mA\$ of collector current.) But only if you changed your voltage rail to the BJTs. If you can't (and I have no reason to believe you can), then those BJTs will still dissipate the same as before. So forget the small signal BJT entirely without changing your whole design and goals. This means you might want to look for a different, rail to rail output type, opamp.

*Now that we've decided that your output is sorely limited to a much smaller output power, your circuit's very significant cross-over distortion will now be terrible and, I'm pretty sure, quite noticeable. You really need a different arrangement to drive those two BJTs, stuck with that LM741. Here I'm thinking of a pair of diodes (optionally tied thermally to your BJTs) and using the opamp to sink a current mirror's current through them.

*You may want to include a small capacitor to help stabilize your voltage divider's mid-point value. Given the substantial input currents used by the LM741, your resistor divider impedance will probably have an impact on the output, as well. I may consider putting a cap there.

I can provide a more specific arrangement for you, based on your existing idea but where these details are accounted. But given that I have no idea what you are using to feed the amplifier as a signal, no idea what kind of 12V power source you are using, and no idea what kind of output power you want, it's really hard to do much more than the above commentary.
ADDED:
Just by way of reference, here's a first improvement step. It's not complete. But it's better. I've left off some of the specific quantities or device numbers, as that's not my point. But I've used specific values to get across some ideas:

simulate this circuit – Schematic created using CircuitLab
The current mirror uses a pair of BJTs that are thermally linked (in the same package) as a BCV62. With the value of \$R_{set}=3.3k\Omega\$ (probably the largest value you should try, as it produces the lowest viable set current you should use), the current available for the output BJT bases will be about \$3.2mA\$ or so. This is enough to keep the diodes with active drops, as well. (Those diodes should probably be thermally coupled to the two output BJTs, as well.) The opamp should be one capable of getting down to within \$\frac{1}{2}V\$ of its (-) rail, or better. (The upper rail has a lesser requirement due to the two diodes.)
This isn't a design. It's just a direction to head to help increase your output power to the load and to reduce (or nearly eliminate, if the BJTs can both be kept ON throughout it) cross-over distortion. It's gain here is set to \$\frac{R_{fb}}{R_{in}}=10\$. This is not what your original circuit shows. It's just a value I chose, for now.

A: Yes, they should work okay. They are rated for higher current and voltage isn't an issue.
Either pair has the potential of overheating in that particular circuit, and that's a particularly nasty audio amplifier circuit with no biasing of the output transistors, so you will get gobs of crossover distortion with a slow op-amp like a 741.
Don't forget to allow for the different transistor pinouts! Eg.

2N3904: E-B-C
   BC337:  C-B-E

Edit: Re crossover distortion see the following two simulations with different op-amps, to illustrate @curd's point in the comment. I'm not suggesting using a 100MHz op-amp in this application, but it does illustrate how a bad output circuit can make an okay-for-audio op-amp like the 741 behave much worse than necessary.

simulate this circuit – Schematic created using CircuitLab

There is still a slight kink in the circuit with the AD797, but it is far more pronounced on the 741 circuit. Because the crossover is inside the negative feedback loop, the op-amp will try to negate it, but the output of the op-amp can only slew so fast, so that dead zone of +.6 to -.6V at the op-amp output takes some time to transition. It's not so important (though it looks much worse) at, say, 10kHz because there is no audible difference to humans between a 10kHz square wave and a sine wave. At 1kHz, on the other hand, the harmonics at 3kHz will be annoyingly audible.
It's preferable to bias the transistors as shown here:

But the circuit shown will produce sound at the output and is simpler (and less prone to possible problems if the bias resistors are wrong).

A: The BCxxx parts you selected, come in a TO-92 plastic package which are underrated for this power requirement.  The 2Nx390x parts come in a TO-88 package rated for higher mW/deg C. THis indicates (inverse of) junction temperature rise above ambient per mW of power dissipated.
When selecting equivalent or better, this factor is important to prevent frying parts.  You should get "better than" original specs using bigger parts with highest hFE for current gain available or use higher impedance earphones.


text:
Q: Login reset/lost in asp.net core containers in kubernetes newbie to containers and coming back to asp.net in nearly a decade and i assumed this would be answered somewhere already but can't seem to locate it !
I have a simple asp.net app running on 3 nodes, the login is per node apparently and is lost when the request is served by a different node. i assumed there would be distributed session management tutorial but coming up short here, any pointers/how-to ?
FYI - in dev for now but for a public facing cloud solution azure/linode/...
running 3 pods
The configuration/logging information is attached below
Redis is working on the localhost - not in a docker container
the behaviour is as follows

*

*say user is logged into pod1, whenever request hits pod1, it shows logged in,

*if the request hits pod2/pod3, it shows not logged in !!!

It looks like something else is required to make the session use redis !!!

public void ConfigureServices(IServiceCollection services)
{
    var cx = Configuration["RedisCache:ConnectionString"];
var redis = ConnectionMultiplexer.Connect(cx);
 services.AddDataProtection().PersistKeysToStackExchangeRedis(redis, "DataProtectionKeys");

    services.AddSession(options =>
    {
        options.IdleTimeout = TimeSpan.FromMinutes(20);
    });
    services.AddControllersWithViews();
    services.AddRazorPages();
}

public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
{
    if (env.IsDevelopment())
    {
        app.UseDeveloperExceptionPage();
        app.UseMigrationsEndPoint();
    }
    else
    {
        app.UseDeveloperExceptionPage();
        //app.UseExceptionHandler("/Error");
        app.UseHsts();
    }
    if (env.IsDevelopment())
    {
        app.UseHttpsRedirection();
    }

    app.UseStaticFiles();

    app.UseRouting();

    app.UseAuthentication();
    app.UseAuthorization();

    // Adds session middleware to pipeline
    app.UseSession();

    app.UseEndpoints(endpoints =>
    {
        endpoints.MapControllerRoute(
            name: "default",
            pattern: "{controller=Home}/{action=Index}/{id?}");
        endpoints.MapRazorPages();
    });
}

APPSETTINGS.JSON
{
  "ConnectionStrings": {
    "DefaultConnection": "Server=host.docker.internal;Database=SAMPLE;Trusted_Connection=false;user id=XXX;password=XXX;MultipleActiveResultSets=true"
  },
  "Logging": {
    "LogLevel": {
      "Default": "Warning",
      "Microsoft": "Warning",
      "Microsoft.Hosting.Lifetime": "Information"
    }
  },
  "RedisCache": {
    "ConnectionString": "host.docker.internal:6379,ssl=True,abortConnect=False"
  },
  "AllowedHosts": "*"
}

I have the following logging information In Index.cshtml.cs
public void OnGet()
{
    var str = $"({Environment.MachineName}) || {HttpContext.Session.Id} || {DateTime.UtcNow.ToString("hh:mm:ss")}: Current({User.Identity.Name})";
    _logger.LogWarning(str);

    string sessionKey = "testKey1";

    HttpContext.Session.SetString(sessionKey, str);
}

A: With the current code, the sessions are stored locally so each time the load balancer redirect to a new pod, you will lose any context of the previous request.
You have to enable distributed caching that will allow to share sessions across multiple instances of your server application. See IDistributedCache interface
You must also ensure that all application instances shared the same keys for Data Protection related workflows.
Here is a working sample with Redis as DistributedCache:
public void ConfigureServices(IServiceCollection services)
{
    // ensure that several instances of the same application can share their session
    services.AddDataProtection()
        .SetApplicationName("myapp_session")
        .PersistKeysToStackExchangeRedis(ConnectionMultiplexer.Connect("redis:6379,password=cE3nNEXHmvGCwdq7jgcxxxxxxxxxx"),
            "DataProtection-Keys");

    services.AddControllersWithViews();

    // add distributed caching based on Redis
    services.AddStackExchangeRedisCache(action => {
        action.InstanceName = "redis";
        action.Configuration = "redis:6379,password=cE3nNEXHmvGCwdq7jgcxxxxxxxxxx";
    });

    services.AddSession(options => {
        options.Cookie.Name = "myapp_session";
        options.IdleTimeout = TimeSpan.FromMinutes(60 * 24);
    });
}

public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
{
    if (env.IsDevelopment())
    {
        app.UseDeveloperExceptionPage();
    }
    else
    {
        app.UseExceptionHandler("/Home/Error");
        // The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
        app.UseHsts();
    }

    app.UseHttpsRedirection();

    app.UseRouting();

    app.UseSession();

    app.UseAuthorization();

    app.UseEndpoints(endpoints =>
    {
        endpoints.MapControllerRoute(
            name: "default",
            pattern: "{controller=Home}/{action=Index}/{id?}");
    });
}

Here is the corresponding csproj:
<Project Sdk="Microsoft.NET.Sdk.Web">
  <PropertyGroup>
    <TargetFramework>net5.0</TargetFramework>
  </PropertyGroup>

  <ItemGroup>
    <PackageReference Include="Microsoft.Extensions.Caching.StackExchangeRedis" Version="5.0.1" />
    <PackageReference Include="Microsoft.AspNetCore.DataProtection.StackExchangeRedis" Version="5.0.3" />
  </ItemGroup>
</Project>

Full sample available here: https://github.com/Query-Interface/SO-Answers/tree/master/dotNET/AspWithSessionOnMultipleNodes
Another option, is to enable SessionAffinity in your Kubernetes Service. It allows the LoadBalancer to root traffic from one client always to the same Pod. It can help you but it is not recommended since as soon as a Pod will be deleted (failing pod or as a result of scaling operation) the LoadBalancer will not be able to route your request to this specific Pod. It is explained in this question: https://stackoverflow.com/questions/56323438


text:
Q: VSTS build for UWP app not producing a .appxupload file Issue: When building a UWP using the VSTS build service no .appxupload file for store submissions is created.
What I did: I created a build definition using the Universal Windows App template that contains 4 build steps. Apart from setting the repository to my external Git repository I didn't change anything.
After the build finishes I only have the _Test folder in my drop. No .appxupload file.
What I tried so far:

*

*According to Build your Universal Windows Plattform app I have to add the UapAppxPackageBuildMode (set to CI) switch to the MSBuild arguments. I did it exactly as shown there. However, neither the .appxupload nor the _Test folder are created but the build step itself completes successfully. (Actually, the AppxPackages folder that is specified by default using the AppxPackageDir switch is missing, too)

*I tried running the Create App Packages... option from within Visual Studio. This results in both, the .appxupload and _Test folder.

*[Update] I found another switch to try at the MSBuild arguments which is AppxPackageIsForStore (set to true). This will generate the _Test folder but still not .appxupload package.

A: I could reproduce your issue. If don't use argument /p:UapAppxPackageBuildMode=CI, I could only get _Test folder. If add argument /p:UapAppxPackageBuildMode=CI, I'll get error message during Publish Artifact step:
Not found PathtoPublish: C:\a\1\b\AppxPackages

But I just tried argument /p:UapAppxPackageBuildMode=StoreUpload, it can generate both _Test folder and .appxupload file, you may have a try.


text:
Q: Window.open without Navigation toolbar I am using the below code to open a new popup window without navigation toolbar. But it's open with the navigation toolbar. Please help me to solve my problem.

A: Popup Script:

Then, you link to it by:
Open popup

Here is another reference:
http://www.gtalbot.org/BugzillaSection/Bug195867GDR_WindowOpen.html


text:
Q: Facebook Messenger bot url not working I have created a test bot using Microsoft bot framework, registered and tested there, all working good.
I have now created a Facebook messenger bot from bot framework UI successfully using this guide(https://learn.microsoft.com/en-gb/bot-framework/channel-connect-facebook)
When ever i go facebook messenger URL provided by Bot Framework (https://www.messenger.com/t/Text-to-Gif-553523584988808), i have been redirected to https://www.messenger.com
Could anyone see this issue before?
Any suggestions would be appreciated.

A: Remove the Text-to-Gif- part of the url.
Your url should be: https://www.messenger.com/t/553523584988808.
I've tested it and that seems to work.


text:
Q: Count the records where a field doesn't equal value X I'm trying to perform a count on results where a field is not equal to a specific value, but it always fails to returns results.
For instance, assuming Company and Products have a one to many relationship, I might get the following array back from ActiveRecord by querying for Company.find(63).products (which would be the SQL equivalent of SELECT "products".* FROM "products" WHERE "products"."company_id" = 63;):
<Product id: 1, company_id: 63, foo_id: 1>,
<Product id: 2, company_id: 63, foo_id: 3>,
<Product id: 3, company_id: 63, foo_id: nil>,
<Product id: 4, company_id: 63, foo_id: nil>

However, if I try to extend the above query to count everything but the first record with the following:
Company.find(63).products.where("foo_id != ?", 1).count

Which in SQL is:
SELECT COUNT(*) FROM "products" WHERE "products"."company_id" = 63 AND (foo_id != 1)

I always seem to get 1 back as a result when I expect to see 3. Why is this happening and how can I get it to count correctly?

A: If it is like you say you should get 1 instead of 0. What you are looking for is DISTINCT FROM as = and != on null types both return unknown as the result.
SELECT COUNT(*) FROM
products
WHERE products.company_id = 63 AND (foo_id IS DISTINCT FROM 1)

http://sqlfiddle.com/#!1/8b7a0/3
And as for further information. DISTINCT FROM is PostgreSQL exclusive so the standard version of doing this would be:
SELECT COUNT(*) FROM
products
WHERE products.company_id = 63 AND (foo_id<>1 OR foo_id IS NULL)

A: have you tried using <> instaed of !=
<>

A: Company.find(63).products.where("foo_id != ?", 1).count

should be
Company.find(63).products.where("foo_id <> ?", 1).count

but you should take it one step further:
class Product
  def self.not_foo(foo_id)
    where("foo_id <> ?", foo_id)
  end
end

now
 Company.find(63).products.not_foo(1).count


text:
Q: How to "calculate" correctly the liquid column height in not "simple" capacities? As I was told on a youtube lesson, to calculate the hydrostatic pressure on the bottom of a capacity, that's on the picture below, I need to use the h1 height(see that formula on the picture). And it totally confuses me, because as I think, the hydrostatic pressure formula in that case must be looking like:
p=F/S, where F=P=mg, where m=Vρ, where V=S*((h1+h2)/2), and then:
↓
p=ρgS*((h1+h2)/2)/S
↓
p=ρg*((h1+h2)/2)

And of course, (h1+h2)/2 < h1, so:

*

*where am I wrong ?

*What liquid column height value do I actually need to take here to calculate the correct value of the hydrostatic pressure at the bottom ?

A: The pressure at the bottom of a column of fluid is
$ P = P_0 + \rho g h$
An important bit of that is $P_0$, the pressure at the top of the column.  For the bit on the right (with the open top), we know the top is either 1 atm (if we care about absolute pressure) or 0 (if we care about gauge pressure).
But on the left, the column is constrained by the container.  This container is providing a pressure downward.  If the container were not rigid enough, the surface could fail and the water would no longer be in this shape.
So the pressure at the bottom of the left column is the same even though the fluid height is different because of the pressure from the container.

where F=P=mg

This only accounts for the pressure due to the mass of the fluid.  The total may be greater due to additional pressure from above the column.
In your problem you can't just look at the mass of the fluid to find the pressure because some pressure is coming from the container as well.

I also don't understand why I "can't look at the mass" if I'm about only the hydrostatic pressure

Because that may only be one part.  Let's imagine a scenario.  You put 1kg of water into a container with a 1 square meter floor.  You can calculate that the pressure at the bottom will be F/A = 9.8Pa.
Now we put a lid on top of the container so it sits right on top of the water.  Then we squeeze the container tight.  If you measure the pressure at the bottom of the container, it will no longer read 9.8Pa, but something much greater.  But the mass of the water hasn't changed at all!    Why?  Because the container is pushing on the top of the water.
The same thing is happening at the top of the h2 column.