text stringlengths 454 608k | url stringlengths 17 896 | dump stringclasses 91
values | source stringclasses 1
value | word_count int64 101 114k | flesch_reading_ease float64 50 104 |
|---|---|---|---|---|---|
From Documentation
Introduction
ZK5 now uses jQuery client side opening up a wide range of possibilities. One of the biggest benefit to use jQuery is that there are a lot of excellent plug-ins, in this Small Talk we will demonstrate the implementation of a client side effect using the jQuery plug-in jQuery Tools which provides a collection of the most important user-interface components for today's websites.
This article is part 1 of a two part series, the second part is located here.
The application’s premise
The premise of the application is to highlight a login area when the user interacts with it. We have a window containing two textboxes which will be highlighted while the background will be masked.
Demo
Including the client side javascript
Including jQuery tools
To get started we need to include the plug-in jQuery tools within the page, this is accomplished by ZK’s script component, shown below.
<?script src="/scripts/tools.expose-1.0.3.js" ?>
We then use the expose method provided by jQuery tools to highlight the Window.
Creating a function to highlight a component
To implement the client side effect we need to create a method which takes a widget as a parameter. The expose functionality is then applied to the widget resulting in highlighting of the given widget.
There are a couple points which need to be noted, firstly, the onLoad event retrieves the inner window which contains the content (in this case the textboxes and labels) to prevent the coloring effect from interfering with the title. Secondly, the onClose event is used to reset the background to the originally defined color. This color must be specified by us or retrieved from elsewhere.
The javascript function to accomplish this task is defined below.
Please remember to house this within <script> tags in your ZUL file.
function exposeLogin (widget) { jq(widget).expose({ // when exposing is done, change form's background color onLoad: function() { jq(widget.$n('cave')).css({backgroundColor: '#c7f8ff'}); }, // when "unexposed", return to original background color onClose: function() { jq(widget.$n('cave')).css({backgroundColor: ""}); }, api: true }).load(); }
Implementing the ZK controls
Using a client side namespace
It is necessary when implementing client side functionality to declare a namespace. By declaring a client side namespace, these events will be resolved at the client rather than server side. Without this namespace applied to your events ZK will think that your code is Java and should be executed at the server.
Defining a namespace
Defining a namespace is easy, you add the following as an attribute to any ZK tag you want to.
xmlns:w=
In the case of our example, this is added to the ZK tag so the namespace is available to all components.
<zk xmlns:
Defining a client side event
The easiest way to define a client side event is to utilize the namespace and utilize attribute tags to encase the javascript code. The following is an extract from our example, please notice that name=”onClick” is prefixed with the declared namespace in the form [NAMESPACE]:name=”[EVENT]”.
<attribute w: //javascript code goes here </attribute>
Applying the effect to the window
In the example the window contains a client side event named onClick (similar to the above code). Within this event the exposeLogin function is called passing “this” as the argument. In this case the argument “this” will reference the window.
Source code
For the complete example please download the source code below. | http://books.zkoss.org/wiki/Small%20Talks/2009/July/ZK%205.0%20and%20jQuery | CC-MAIN-2014-15 | refinedweb | 578 | 60.75 |
#include <unordered_map_concurrent.h>
An unordered_map_concurrent::iterator points to a specific entry in the umc, and holds a lock to the bin the entry is in.
Definition at line 92 of file unordered_map_concurrent.h.
Construct an unordered_map_concurrent iterator that points to nothing.
Definition at line 100 of file unordered_map_concurrent.h.
Copy constructor of an unordered_map_concurrent iterator transfers the lock (if held) to this. Caveat: the copied iterator no longer holds the lock!
Definition at line 110 of file unordered_map_concurrent.h.
Destroying an unordered_map_concurrent iterator releases any bin locks it held.
Definition at line 122 of file unordered_map_concurrent.h.
Totally invalidate this iterator – point it to nothing (releasing any locks it may have had).
Definition at line 126 of file unordered_map_concurrent.h.
Without changing the lock status (i.e., the caller already holds the lock on the iterator's bin), increment to the next element within the bin. Return true if it's pointing to a valid element afterwards, false if it ran off the end of the bin contents.
Definition at line 223 of file unordered_map_concurrent.h.
Lock the bin we point to, if not already locked.
Definition at line 202 of file unordered_map_concurrent.h.
Treating an iterator as a bool yields true if it points to a valid element of one of the bins of the map, false if it's equivalent to the end() iterator.
Definition at line 151 of file unordered_map_concurrent.h.
Definition at line 179 of file unordered_map_concurrent.h.
Definition at line 136 of file unordered_map_concurrent.h.
Increment to the next entry in the map. If we finish the bin we're in, move on to the next bin (releasing our lock on the old bin and acquiring a lock on the new bin). If we finish the last bin of the map, return the end() iterator.
Definition at line 185 of file unordered_map_concurrent.h.
Definition at line 199 of file unordered_map_concurrent.h.
Dereferencing returns a reference to the hash table entry the iterator refers to.
Definition at line 143 of file unordered_map_concurrent.h.
Iterator assignment transfers ownership of any bin locks held by the operand.
Definition at line 159 of file unordered_map_concurrent.h.
Definition at line 171 of file unordered_map_concurrent.h.
Unlock the bin we point to, if locked.
Definition at line 210 of file unordered_map_concurrent.h.
Definition at line 95 of file unordered_map_concurrent.h. | https://www.sidefx.com/docs/hdk/classunordered__map__concurrent_1_1iterator.html | CC-MAIN-2021-43 | refinedweb | 389 | 52.15 |
This is the mail archive of the libstdc++@sources.redhat.com mailing list for the libstdc++ project.
On 07 Jul 2000 at 01:36 (-0600), llewelly@dbritsch.dsl.xmission.com wrote: | | Old style header names like iostream.h, fstream.h are not part of the | ISO C++ standard. The standard names have no .h . (e.g. iostream, map | list, etc) On a similar note: Would it be sane to shipmake available a set of 'compatibility' headers similar to the following? brent@sleepy$ cat ./iostream.h #warning <iostream.h> is not a standard c++ header #warning update this code to use <iostream> #ifndef __NONSTD_HACK__ #define __NONSTD_HACK__ #include <iostream> using namespace std; #endif I ask because I've had to do just this to get some old (rather, noncompliant) code to compile with a libstdc++-v3 gcc. If there is any interest, let me know and I'll start on this when I get a spare moment. Brent -- Damon Brent Verner o _ _ _ Cracker Jack? Surprise Certified _o /\_ _ \\o (_)\__/o (_) brent@rcfile.org _< \_ _>(_) (_)/<_ \_| \ _|/' \/ brent@linux1.org (_)>(_) (_) (_) (_) (_)' _\o_ | http://gcc.gnu.org/ml/libstdc++/2000-07/msg00114.html | CC-MAIN-2019-26 | refinedweb | 197 | 76.11 |
Python OS
I had to make this:
This nice right?
Not really an os. See ya.
elburg (37)
Oh shoot! I forgot it's time.struct_time(tm_year=2020, tm_mon=11, tm_mday=4, tm_hour=22, tm_min=20, tm_sec=16, tm_wday=2, tm_yday=309, tm_isdst=0)! Time for me to go!
hg0428 (192)
At least clear the screen every once in a while and color your text.
At least clear the screen every once in a while and color your text.
If you do not know how to clear the screen or color text:
import replit replit.clear() #clears the screen print("\033[91mThis text is colored in red!\033[00m") #prints out "This text is colored in red!" in red to the terminal
It is good.
I will update it soon. | https://replit.com/talk/share/Python-OS/4273 | CC-MAIN-2021-17 | refinedweb | 130 | 96.48 |
I have a class like this
public class TestData
{
public string Name {get;set;}
public string type {get;set;}
public List<string> Members = new List<string>();
public void AddMembers(string[] members)
{
Members.AddRange(members);
}
}
I want to know if it is possible to directly compare to instances of this class to eachother and find out they are exactly the same? what is the mechanism? I am looking gor something like
if(testData1 == testData2) //Do Something And if not, how to do so?
You should implement the
IEquatable<T> interface on your class, which will allow you to define your equality-logic.
Actually, you should override the
Equals method as well.
public class TestData : IEquatable<TestData> { public string Name {get;set;} public string type {get;set;} public List<string> Members = new List<string>(); public void AddMembers(string[] members) { Members.AddRange(members); } // Overriding Equals member method, which will call the IEquatable implementation // if appropriate. public override bool Equals( Object obj ) { var other = obj as TestData; if( other == null ) return false; return Equals (other); } public override int GetHashcode() { // Provide own implementation } // This is the method that must be implemented to conform to the // IEquatable contract public bool Equals( TestData other ) { if( other == null ) { return false; } if( ReferenceEquals (this, other) ) { return true; } // You can also use a specific StringComparer instead of EqualityComparer<string> // Check out the specific implementations (StringComparer.CurrentCulture, e.a.). if( EqualityComparer<string>.Default.Compare (Name, other.Name) == false ) { return false; } ... // To compare the members array, you could perhaps use the // [SequenceEquals][2] method. But, be aware that [] {"a", "b"} will not // be considerd equal as [] {"b", "a"} return true; } }
There are three ways objects of some reference type
T can be compared to each other:
object.Equalsmethod
IEquatable<T>.Equals(only for types that implement
IEquatable<T>)
==
Furthermore, there are two possibilities for each of these cases:
T(or some other base of
T)
object
The rules you absolutely need to know are:
Equalsand
operator==is to test for reference equality
Equalswill work correctly no matter what the static type of the objects being compared is
IEquatable<T>.Equalsshould always behave the same as
object.Equals, but if the static type of the objects is
Tit will offer slightly better performance
So what does all of this mean in practice?
As a rule of thumb you should use
Equals to check for equality (overriding
object.Equals as necessary) and implement
IEquatable<T> as well to provide slightly better performance. In this case
object.Equals should be implemented in terms of
IEquatable<T>.Equals.
For some specific types (such as
System.String) it's also acceptable to use
operator==, although you have to be careful not to make "polymorphic comparisons". The
Equals methods, on the other hand, will work correctly even if you do make such comparisons.
You can see an example of polymorphic comparison and why it can be a problem here.
Finally, never forget that if you override
object.Equals you must also override
object.GetHashCode accordingly.
One way of doing it is to implement
IEquatable<T>
public class TestData : IEquatable<TestData> { public string Name {get;set;} public string type {get;set;} public List<string> Members = new List<string>(); public void AddMembers(string[] members) { Members.AddRange(members); } public bool Equals(TestData other) { if (this.Name != other.Name) return false; if (this.type != other.type) return false; // TODO: Compare Members and return false if not the same return true; } } if (testData1.Equals(testData2)) // classes are the same
You can also just override the Equals(object) method (from System.Object), if you do this you should also override GetHashCode see here
You can override the equals method and inside it manually compare the objects
Also take a look at Guidelines for Overloading Equals() and Operator ==
You will need to define the rules that make object A equal to object B and then override the Equals operator for this type.
First of all equality is difficult to define and only you can define as to what equality means for you
Here is a discussion and an answer here
What is "Best Practice" For Comparing Two Instances of a Reference Type?
Implement the
IEquatable<T> interface. This defines a generalized method that a value type or class implements to create a type-specific method for determining equality of instances. More information here: | http://www.dlxedu.com/askdetail/3/d8a79d2ab0459ec26105ec3b70c094eb.html | CC-MAIN-2018-43 | refinedweb | 718 | 53.1 |
Notes on PEAR_Exception
I've been doing some thinking on exceptions, and
PEAR_Exception
in particular. You may want to skip ahead to read about how to use
PEAR_Exception, as well as some of my thoughts on the class on first use. If
you want the background, read on.
I've created a package proposal on PEAR for a package called File_Fortune, an OOP interface to reading and writing fortune files. I've been using a perl module for this on the family website for years, and now that I'm starting work on the PHP conversion, I thought I'd start with the building blocks.
In creating the proposal, I started with a PHP5-only version, though I found
that I wasn't using much in PHP5 beyond the
public/
private/
protected/
static
keywords. For error handling, I decided to try out
PEAR_ErrorStack, as I'd been
hearing buzz about it being the new "preferred" method for error handling in
PEAR. (Honestly, after using it, I'm not too happy with it; throwing
PEAR_Errors was much easier, and easier to manipulate as well — but that's a
subject for another post — and exceptions were easier still, though more
typing.)
The first comment I got on the proposal was the question: "Why PHP5?" (Paul wasn't too surprised by that reaction.) I thought about it, and decided it wasn't really all that necessary, beyond the fact that I'd need to take some extra steps to be able to actually test a PHP4 version. So, I did a PHP4 version.
Well, then some chatter happened, and a number of developers said, "Why not
PHP5?" So, I went back to PHP5. And then somebody else said, "Use
PEAR_Exception." So, I started playing with that, and we finally get to the
subject of this post.
Exception handling is one of the advances PHP5 brought to PHP. I was very excited to have it available, as I'm accustomed to exception handling in perl (which is actually quite different than PHP's model, but the basics are the same). When I saw the suggestion to use it, I realized that exception handling would make the package solidly a PHP5 package. Simultaneously, I wondered why it hadn't occurred to me. Guess I've been coding more PHP than perl for a while now…
The problem is that there's very little documentation on
PEAR_Exception, and
the tips I got on list, while helpful in getting my proposal out the door, left
me with a lot of questions.
For those who haven't used
PEAR_Exception, here's the basics:
Create a file in which to hold your exceptions classes. (Yes, plural; I'll get to that). If you're developing a PEAR-style package, you want to put it in the directory pertaining to your package name. So, since I was developing
File_Fortune, my exception class became
File/Fortune/Exception.php.
Create a base exception class for your class that extends
PEAR_Exception:
class File_Fortune_Exception extends PEAR_Exception { }
Note: it doesn't override anything. It just creates a pseudo-namespace.
For each unique exception type, extend your base class:
class File_Fortune_FileException extends File_Fortune_Exception { } class File_Fortune_HeaderException extends File_Fortune_Exception { }
(Yes, you should create docblocks for each, describing their purpose.)
In your code, throw exceptions instead of raising errors:
if (false === ($fh = fopen($filename))) { throw new File_Fortune_FileException('Unable to open file'); }
In your phpDoc blocks, use
@throws Exception_Class_Namewith some descriptive text
And that's it in a nutshell.
The beauty of it is that you can really separate errors from return values — errors are no longer a possible return value:
try { $fortune = $ff->getRandom(); } catch (File_Fortune_Exception $e) { echo "Couldn't get fortune: " . $e->getMessage(); }
The problem I saw with the system is that you end up with a bunch of exception classes, each of which has a veeeerrryyy looooonnnnngggg name, which leads to lots of typing, the possibility for typos (I had one in the version I used for the call to votes), and the possibility for more error handling than code, depending on the number of possible exceptions and how carefully you want to check for them:
try { $fortune = $ff->getRandom(); } catch (File_Fortune_BadHeaderFileException $e) { echo "Could not parse header file"; } catch (File_Fortune_HeaderFileException $e) { echo "Could not open header file"; } catch (File_Fortune_BadFileException $e) { echo "Badly formed fortune file"; } catch (File_Fortune_Exception $e) { // Catch-all for File_Fortune errors... echo "Couldn't get fortune: " . $e->getMessage(); }
I got to thinking that there must be a better way. I haven't actually come up
with one yet, though. My idea so far, however, is to have a single exception
class, and in it define a number of class constants or statics — much like
PEAR_Error/
PEAR_ErrorStack, where they map to integer values — and to have
these values map to actual error messages (which could possibly be localized
within the class as well). Then, when throwing an error, it might be something
like:
if (false === ($fh = fopen($filename))) { throw new File_Fortune_Exception(1); } // or if (false === ($fh = fopen($filename))) { throw new File_Fortune_Exception(File_Fortune_Exception::FILE); }
The constructor would be overridden to set the code and message based on the
code passed (if a string was passed, that would be the message). Then you could
test for a single exception class, and use
$e->getCode() to check for the
type if you need more fine-grained control.
I'd be more than happy to discuss possibilities. Exceptions are a fantastic way to check for truly exceptional behaviour in code; in PHP5, they also seem to be incredibly fast and lightweight (though I have no substantive data to back that statement, other than API responsiveness). I'd like to see more people developing with them.
On that note, what do other PHP develpers think of exception handling? I've
heard some say it's too 'goto-ish' (I'm not sure I follow that train of
thought), others prefer the simplicity of
PEAR_Error. Leave a comment! | https://mwop.net/blog/81-Notes-on-PEAR_Exception.html | CC-MAIN-2016-18 | refinedweb | 987 | 57.91 |
Thread
2002.08.24 12:12 "Re: Recover tiff file", by Agneta Johner
Hi Phillip!
Thank you for letting me know! It was actually also the wrong file copied there at the time you had a look. My apologizes for the mistake! The correct files are present now, and this time the transfer mode was binery.
Thank you again for letting me know, best regards Agneta
I'm not sure if it happened before you started uploading the file, or if it's happening now, but the file is/was transferred in ASCII mode, which is adding a carriage return (0x0d) before each linefeed (0x0a).
Phillip
Thanks for taking your time with my problem. The file was ok before it was copied to another location ( and unfortunately the original was removed!). When trying to open it in Photoshop I got the message "Can't open this tiff document because it contains to many bits". I tried the pmview tool ( found at Peter Nielsen: thanks for the tip! ) and got the message"Unsupported data: Bits per sample =0"
I checked the tag info using a tool called Tagsviewer ( found at) and the info looked ok. Anybody interested can find the file here if you want to have a look:
It's unfortunately pretty big ( 55 Mb), a smaller jpeg version is also present....
>> Agneta Johnér
--
Agneta Johnér
Johnér Bildbyrå AB
Johnér Interactive
Åsögatan 144
116 24 Stockholm
Tel: +46 (0)8 6448330
Hemsida: | https://www.asmail.be/msg0055240074.html | CC-MAIN-2021-10 | refinedweb | 242 | 70.33 |
Subject: [boost] Many Boost.Test unit tests fail
From: Barend Gehrels (barend_at_[hidden])
Date: 2011-12-29 18:47:08
Hi,
Since today or yesterday, many regression tests fail.
I believe on platforms that are recently added, at last on platforms
that were not present at December 17.
1) on clang/darwin, message
../boost/test/tools/assertion.hpp:278:21: error: no member named 'forward' in namespace 'std'
2) on clang/linux, message
/usr/bin/ld: skipping incompatible /sierra/Sntools/extras/compilers/gcc-4.4.4/lib/libstdc++.so when searching for -lstdc++
We have these errors in Boost.Geometry but I also noticed them in many
other libraries.
Regards, Barend
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk | https://lists.boost.org/Archives/boost/2011/12/189181.php | CC-MAIN-2020-40 | refinedweb | 133 | 53.78 |
LaTeX is a typesetting language for producing scientific documents. We use a very small part of the language for writing mathematical notation. Jupyter notebook recognizes LaTeX code written in markdown cells and renders the symbols in the browser using the MathJax JavaScript library.
To write a LaTeX formula in the legend of a plot, we can take the following steps −
Create data points for x.
Create data point for y, i.e., y=sin(x).
Plot the curve x and y with LaTex representation.
To activate the label, use the legend() method.
To display the figure, use the show() method.
import numpy as np import matplotlib.pyplot as plt plt.rcParams["figure.figsize"] = [7.50, 3.50] plt.rcParams["figure.autolayout"] = True x = np.linspace(1, 10, 1000) y = np.sin(x) plt.plot(x, y, label=r'$\sin (x)$', c="red", lw=2) plt.legend() plt.show()
Put a little more complex equation in the label, for example, label=r'$\alpha^{i \pi} + 1 = 0$'
Now, look at the legend at the top-right corner of the plot. | https://www.tutorialspoint.com/how-do-i-write-a-latex-formula-in-the-legend-of-a-plot-using-matplotlib-inside-a-py-file | CC-MAIN-2021-43 | refinedweb | 179 | 60.51 |
Minimal task scheduling abstraction
Project description
Dask provides multi-core execution on larger-than-memory datasets using blocked algorithms and task scheduling. It maps high-level NumPy, Pandas, and list operations on large datasets on to many operations on small in-memory datasets. It then executes these graphs in parallel on a single machine. Dask lets us use traditional NumPy, Pandas, and list programming while operating on inconveniently large data in a small amount of space.
- dask is a specification to describe task dependency graphs.
- dask.array is a drop-in NumPy replacement (for a subset of NumPy) that encodes blocked algorithms in dask dependency graphs.
- dask.bag encodes blocked algorithms on Python lists of arbitrary Python objects.
- dask.dataframe encodes blocked algorithms on Pandas DataFrames.
- dask.async is a shared-memory asynchronous scheduler efficiently execute dask dependency graphs on multiple cores.
See full documentation at or read developer-focused blogposts about dask’s development.
Use dask.array
Dask.array implements a numpy clone on larger-than-memory datasets using multiple cores.
>>> import dask.array as da >>> x = da.random.normal(10, 0.1, size=(100000, 100000), chunks=(1000, 1000)) >>> x.mean(axis=0)[:3].compute() array([ 10.00026926, 10.0000592 , 10.00038236])
Use dask.dataframe
Dask.dataframe implements a Pandas clone on larger-than-memory datasets using multiple cores.
>>> import dask.dataframe as dd >>> df = dd.read_csv('nyc-taxi-*.csv.gz') >>> g = df.groupby('medallion') >>> g.trip_time_in_secs.mean().head(5) medallion 0531373C01FD1416769E34F5525B54C8 795.875026 867D18559D9D2941173AD7A0F3B33E77 924.187954 BD34A40EDD5DC5368B0501F704E952E7 717.966875 5A47679B2C90EA16E47F772B9823CE51 763.005149 89CE71B8514E7674F1C662296809DDF6 869.274052 Name: trip_time_in_secs, dtype: float64
Use dask.bag
Dask.bag implements a large collection of Python objects and mimicing the toolz interface
>>> import dask.bag as db >>> import json >>> b = db.from_filenames('2014-*.json.gz') ... .map(json.loads) >>> alices = b.filter(lambda d: d['name'] == 'Alice') >>> alices.take(3) ({'name': 'Alice', 'city': 'LA', 'balance': 100}, {'name': 'Alice', 'city': 'LA', 'balance': 200}, {'name': 'Alice', 'city': 'NYC', 'balance': 300}, >>> dict(alices.pluck('city').frequencies()) {'LA': 10000, 'NYC': 20000, ...}
Use Dask Graphs
Dask.array, dask.dataframe, and dask.bag are thin layers on top of dask graphs, which represent computational task graphs of regular Python functions on regular Python objects.
As an example consider the following simple program:
def inc(i): return i + 1 def add(a, b): return a + b x = 1 y = inc(x) z = add(y, 10)
We encode this computation as a dask graph in the following way:
d = {'x': 1, 'y': (inc, 'x'), 'z': (add, 'y', 10)}
A dask graph is just a dictionary of tuples where the first element of the tuple is a function and the rest are the arguments for that function. While this representation of the computation above may be less aesthetically pleasing, it may now be analyzed, optimized, and computed by other Python code, not just the Python interpreter.
Install
Dask is easily installable through your favorite Python package manager:
conda install dask or pip install dask[array] or pip install dask[bag] or pip install dask[dataframe] or pip install dask[complete]
Dependencies
dask.core supports Python 2.6+ and Python 3.3+ with a common codebase. It is pure Python and requires no dependencies beyond the standard library. It is a light weight dependency.
dask.array depends on numpy.
dask.bag depends on toolz and dill.
Examples
Dask examples are available in the following repository:.
You can also find them in Anaconda.org:.
LICENSE
New BSD. See License File.
Project details
Release history Release notifications
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages. | https://pypi.org/project/dask/0.7.1/ | CC-MAIN-2019-43 | refinedweb | 601 | 60.92 |
Learning Java/Programming tips
When to use methods[edit | edit source]
The ideal method only handles one function, and is named appropriately. Using methods increases readability of your code and makes it easier to expand or change your software. You can also call your methods from separate places, reducing the total number of lines of code. Methods are also used to retrieve data from an object and store data in objects. These methods are called getters and setters. Example:
public class Customer {; } }
Methods are allowed to call other methods, but only if they have a different functions. Try using common sense when deciding whether use methods or not. There are multiple analysis tools to see if you are using methods right and efficiently. You should avoid having methods with a lot of lines of code, it often (but not always) indicates that the method can be broken up in smaller methods.
About Arrays[edit | edit source]
Arrays should be used for variables that have something to do with each other. Basically, arrays are a sets of variables, and arrays are a variable themselves.
Here are some examples which declare arrays.
int[] var; // declares an array of ints String[] stringArray; // declares an array of Strings Object[] objArray; // declares an array of Objects
Simply declaring an array in this way does not allocate space for the elements of the array. Declaring the array with a list of elements will allocate the space for the elements and also assign their values.
int[] intArray = {0, 1, 2, 3}; // declare an array of ints with 4 assigned elements
To create an array one must use the new operator and specify the length of the array.
var = new var[8]; // instantiate the array with 8 elements //Put into one statement int[] myInts = new int[22]; // declare a new array and instantiate it with 22 elements;
Each array has an int member called length. It is simply how many items are in the array.
int myCount = myInts.length; // assign the size of an array to a variable
You need to initialize each part of the array. To "access" the members of the array:
myInts[2] = 3; int var = myInts[2];
Note: Do NOT use arrays when the members have nothing to do with each other. This causes code errors!
Basic Tips for Improving Code[edit | edit source]
Code formatting[edit | edit source]
Code formatting is necessary to understand your code more easily. For example, the following is very hard to understand because it is not properly formatted:
public class MessyCoding extends Coding {public static void main(String args[] ){System.out.println ("This is messy coding. Don't do this");System.exit(0);}}
In much better format:
public class CleanCoding extends Coding { public static void main(String args[]) { System.out.println("This is clean coding. DO THIS!!"); System.exit(0); } }
Notice that the code is easier to understand. Every single new block that has { and } should have whitespace preceding it. Example:
public class CleanCoding extends Coding { public static void main(String args[]) { try{ try{ ...; } ...; } ...; } ...; }
To further improve the readability of your code, you should insert one empty line between methods:
public void method1() { }
A good alternative is:
public void method2() { }
You should make a new line after every statement/declaration. If a statement is too long, you can break it down.
Some Integrated Development Environments like Netbeans IDE have an auto-formatting function built in.
Good Comments[edit | edit source]
Good comments can help make your code look neat. They should tell what you are doing overall, not what you are doing on each line. For example, you can comment an if statement if it is complex, but not every statement has to be commented:
// tests for parity, sign, and size if( x%2 == 0 && x > 0 && x < 1000 ) { System.out.println("x is a positive, even, integer less than 1000"); if( x%3 == 0 ) // tests if divisible by 3 x++; }
An example of bad commenting would be:
if( i1 == i2 | i1 == i3 ) // Check if i1 is equal to i2 and i3 { System.out.println( "YES!" ); // Print Yes! to the command line i1= i1 + 1; // Add 1 to i1 }
Quick way to convert numbers to strings[edit | edit source]
There will be a lot of times you need a String and you're working with numbers. This is one of the faster ways to convert numbers to String, but it's not very neat.
int a = 5; double b = 3; String aAsString = "" + a; String bAsString = "" + b; or String aAsString = String.valueOf(a); String bAsString = String.valueOf(b); or String aAsString = Integer.toString(a); String bAsString = Double.toString(b);
Getting numbers from strings[edit | edit source]
When you need to extract numbers from a string you can use the Wrapper classes to parse them into the number you need.
String stringInt = "153"; String stringDouble = "56.324"; int myInt = Integer.parseInt(stringInt); double myDouble = Double.parseDouble(stringDouble); | https://en.wikiversity.org/wiki/Java_programming_tips | CC-MAIN-2022-05 | refinedweb | 817 | 63.39 |
In one of my mobile apps, I needed to add a count down timer – which counts back from a specified time to zero time. I was preparing to create the same from the scratch until I saw this new third-party library named react native countdown timer.
Even though the react native library is relatively new, I choose it instead of reinventing the wheel. The timer component is easy to implement as well as customize. ‘
All you have to do is
npm install –save react-native-timer-countdown
Following is the example code to implement countdown timer in react native. For more details, you can check the official page.
import React from "react"; import { StyleSheet, View } from "react-native"; import TimerCountdown from "react-native-timer-countdown"; const App = () => ( <View style={styles.container}> <TimerCountdown initialMilliseconds={1000 * 60} onTick={(milliseconds) => console.log("tick", milliseconds)} onExpire={() => console.log("complete")} formatMilliseconds={(milliseconds) => { const remainingSec = Math.round(milliseconds / 1000); const seconds = parseInt((remainingSec % 60).toString(), 10); const minutes = parseInt(((remainingSec / 60) % 60).toString(), 10); const hours = parseInt((remainingSec / 3600).toString(), 10); const s = seconds < 10 ? '0' + seconds : seconds; const m = minutes < 10 ? '0' + minutes : minutes; let h = hours < 10 ? '0' + hours : hours; h = h === '00' ? '' : h + ':'; return h + m + ':' + s; }} allowFontScaling={true} style={{ fontSize: 20 }} /> </View> ); const styles = StyleSheet.create({ container: { flex: 1, backgroundColor: "#fff", alignItems: "center", justifyContent: "center" } }); export default App; | https://reactnativeforyou.com/how-to-add-a-count-down-timer-to-react-native-app/ | CC-MAIN-2021-31 | refinedweb | 227 | 52.36 |
File transfer is the process of copying or moving a file from a computer to another over a network or Internet connection. In this tutorial we'll go step by step on how you can write quick client/server Python scripts that handles that.
The basic idea is to create a server that listens on a particular port, this server will be responsible for receiving files (you can make the server sends files as well). On the other hand, the client will try to connect to the server and send any file of any type.
We are going to use socket module which comes built-in with Python and provides us with socket operations that are widely used on the Internet, as they are behind of any connection to any network.
Related: How to Send Emails in Python using smtplib Module.
First, we gonna need to install tqdm which will enable us to print fancy progress bars:
pip3 install tqdm
Let's start with the client, the sender:
import socket import tqdm import os SEPARATOR = "<SEPARATOR>" BUFFER_SIZE = 4096 # send 4096 bytes each time step
We need to specify the IP address and the port of the server we want to connect to, and also the name of the file we want to send.
# the ip address or hostname of the server, the receiver host = "192.168.1.101" # the port, let's use 5001 port = 5001 # the name of file we want to send, make sure it exists filename = "data.csv" # get the file size filesize = os.path.getsize(filename)
The filename needs to exist in the current directory, or you can use an absolute path to that file somewhere in your computer.
os.path.getsize(filename) gets the size of that file in bytes, that's great, as we need it for printing progress bars in the client and the server.
Let's create the TCP socket:
# create the client socket s = socket.socket()
Connecting to the server:
print(f"[+] Connecting to {host}:{port}") s.connect((host, port)) print("[+] Connected.")
connect() method expects an address of the pair (host, port) to connect the socket to that remote address.
Once the connection is established, we need to send the name and size of the file in bytes:
# send the filename and filesize s.send(f"{filename}{SEPARATOR}{filesize}".encode())
I've used SEPARATOR here just to separate the data fields, it is just a junk message, we can just use send() twice, but we may don't wanna do that anyways. encode() function encodes the string we passed to 'utf-8' encoding (that's necessary).
Now we need to send the file, and as we are sending the file, we'll print nice progress bars using tqdm library:
# start sending the file progress = tqdm.tqdm(range(filesize), f"Sending {filename}", unit="B", unit_scale=True, unit_divisor=1024) with open(filename, "rb") as f: for _ in progress: # read the bytes from the file bytes_read = f.read(BUFFER_SIZE) if not bytes_read: # file transmitting is done break # we use sendall to assure transimission in # busy networks s.sendall(bytes_read) # update the progress bar progress.update(len(bytes_read)) # close the socket s.close()
Basically what we are doing here is opening the file as read in binary, read chunks from the file (in this case, 4096 bytes or 4KB) and send them to the socket using sendall() function, and then we update the progress bar each time, once that's finished, we close that socket.
Alright, so we are done with the client. Let's dive into the server, so open up a new empty Python file and:
import socket import tqdm import os # device's IP address SERVER_HOST = "0.0.0.0" SERVER_PORT = 5001 # receive 4096 bytes each time BUFFER_SIZE = 4096 SEPARATOR = "<SEPARATOR>".
Also, Make sure you use the same port in the server as in the client.
Let's create our TCP socket:
# create the server socket # TCP socket s = socket.socket()
Now this is different from the client, we need to bind the socket we just created to our SERVER_HOST and SERVER_PORT:
# bind the socket to our local address s.bind((SERVER_HOST, SERVER_PORT))
After that, we gonna listen for connections:
# enabling our server to accept connections # 5 here is the number of unaccepted connections that # the system will allow before refusing new connections s.listen(5) print(f"[*] Listening as {SERVER_HOST}:{SERVER_PORT}")
Once the client connects to our server, we need to accept that connection:
# accept connection if there is any client_socket, address = s.accept() # if below code is executed, that means the sender is connected print(f"[+] {address} is connected.")
Remember that when the client is connected, it'll send the name and size of file, let's receive them:
# receive the file infos # receive using client socket, not server socket received = client_socket.recv(BUFFER_SIZE).decode() filename, filesize = received.split(SEPARATOR) # remove absolute path if there is filename = os.path.basename(filename) # convert to integer filesize = int(filesize)
As mentioned earlier, the received data is combined of the filename and and the filesize, we can easily extract them by splitting by SEPARATOR string.
After that, we need to remove the absolute path of the file, that's because the sender sent the file with his own file path, which may differ from ours, os.path.basename() returns the final component of a path name.
Now we need to receive the file:
# start receiving the file from the socket # and writing to the file stream progress = tqdm.tqdm(range(filesize), f"Receiving {filename}", unit="B", unit_scale=True, unit_divisor=1024) with open(filename, "wb") as f: for _ in progress: # read 1024 bytes from the socket (receive) bytes_read = client_socket.recv(BUFFER_SIZE) if not bytes_read: # nothing is received # file transmitting is done break # write to the file the bytes we just received f.write(bytes_read) # update the progress bar progress.update(len(bytes_read)) # close the client socket client_socket.close() # close the server socket s.close()
Not quite different from the client code. However, we are opening the file as write in binary here, and using recv(BUFFER_SIZE) to receive BUFFER_SIZE bytes from the client socket and write it to the file. Once that's finished, we close both the client and server sockets.
Let me try it on my own network:
C:\> python receiver.py [*] Listening as 0.0.0.0:5001
I need to go to my linux box and send some example file:
root@rockikz:~/tools# python3 sender.py [+] Connecting to 192.168.1.101:5001 [+] Connected. Sending data.npy: 9%|███████▊ | 45.5M/487M [00:14<02:01, 3.80MB/s]
Let's see the server now:
[+] ('192.168.1.101', 47618) is connected. Receiving data.npy: 33%|███████████████████▍ | 160M/487M [01:04<04:15, 1.34MB/s]
Great, we are done!
You can extend this code for your own needs now, here are some examples you can implement:
Read Also: How to Manipulate IP Addresses in Python using ipaddress Module.
Happy Coding ♥View Full Code | https://www.thepythoncode.com/article/send-receive-files-using-sockets-python | CC-MAIN-2020-16 | refinedweb | 1,164 | 71.14 |
Curious about React Context, using an HoC to generalize a context consumer, why you might need to use contextType, or what is prop-drilling? 🤔
If yes, cool! Read on because this might be the guide that'll help you get started with context.
Intro: Why you need React Context ?
Let's say you have a
Card component that gets the style from the current theme of
App, so you end up passing the theme from
App to
Card, involving all the components in between unnecessarily.
App --theme-->
Container --theme-->
Section --theme-->
ThemedCard --theme-->
Card
In code, it might look like this:
// Card.jsx import React from 'react'; import styles from './styles'; const Card = (props) => ( <div style={styles[props.theme]}> <h1>Card</h1> </div> ) export default Card; // App.jsx import React from 'react'; const ThemedCard = (props) => <Card theme={props.theme} /> const Section = (props) => <ThemedCard theme={props.theme} /> const Container = (props) => <Section theme={props.theme} /> class App extends React.Component { state = { theme: 'dark', } switchTheme = () => { const newTheme = this.state.theme === "dark" ? "default" : "dark"; this.setState({ theme: newTheme }); }; render() { return ( <div> <button onClick={this.switchTheme}>Switch theme</button> <Container theme={this.state.theme} /> </div> ); } } export default App;
Code for part 1 here:
This is called prop-drilling, and this gets even worse if you have more layers of components between the data source and user. One really good alternative is using Context.
createContext
First thing is to create a context using
React.createContext.
// ThemeContext.jsx import React from "react"; const ThemeContext = React.createContext(); export default ThemeContext;
Context Provider:
<ThemeContext.Provider>
Now we can wrap all the context users with the Context Provider, and pass the
value that we want to 'broadcast'.
The value that we pass becomes the actual context later, so you can decide to put a single value or an entire object here.
Note: We choose to do
value={this.state}so we later access
context.theme. If we do
value={this.state.theme}, we access it via
context
// App.jsx ... import ThemeContext from "./ThemeContext"; ... return ( <div> <button onClick={this.switchTheme}>Switch theme</button> <ThemeContext.Provider value={this.state}> <Container /> </ThemeContext.Provider> </div> ); ...
So how do we access the
theme from its descendant
Card ?
Context Consumer:
<ThemeContext.Consumer>
To access the context, we use a context consumer
<ThemeContext.Consumer> from any ancestor of
Card.
Here we choose
ThemedCard so we keep the
Card presentational, without any context stuff.
Consumer gives access to the context and propagates it downwards.
The caveat is that it requires a function child that takes the context value as a prop and returns React node that uses the context value.
This is also known as a render prop pattern. More about render prop here.
<SomeContext.Consumer> {(context_value) => (<div> ...do something with context_value </div>) } </SomeContext.Consumer>
In our case, we render
<Card> taking the
theme from the context object.
We destructure theme using
({theme}), but you can also do
(context) => ...context.theme, and/or add stuff to our App state and access them here via
({theme, name}), which we will do later.
Note that we don't have to pass the
theme prop to Container anymore, and we also don't need the
theme prop from Section anymore, since we can 'tap' directly into the context using the Consumer.
// App.jsx ... const ThemedCard = () => ( <ThemeContext.Consumer> {({theme}) => <Card theme={theme} />} </ThemeContext.Consumer> ) ... const Section = () => <ThemedCard /> const Container = () => <Section />
Finally, we can use the theme in our Card to style it.
// Card.jsx ... const Card = props => ( <div style={styles[props.theme]}> <h1>Card</h1> </div> ) ...
Code in part 2 here:
Now our context provider and consumer works great!
We have our root component
<App /> that holds the state, propagating it through the Provider and a presentation component
<ThemedCard /> that uses a Consumer to access the context and use it to style
<Card />.
Using a Higher Order Component (HoC) to generalize a Context container
Having a
ThemedCard is nice for theming
Cards but what if we want to theme other things, like an Avatar, Button, or Text. Does that mean we have to create
Themed... for each of these?
We could, but there is a better way to generalize the theming container so we can use it for any component we want to use our theme context.
withTheme HoC
A HoC in React is a function that takes a component and returns another component.
Instead of a
ThemedWhatever, we create a
withTheme HoC that returns a generic component
ThemedComponent that wraps ANY component we want to theme with the Context Consumer.
So whatever that component is: Card, Avatar, Button, Text, whatever, it would have access to our context! 😃
// withTheme.js import React from "react"; import ThemeContext from "./ThemeContext"; const withTheme = Component => { class ThemedComponent extends React.Component { render() { return ( <ThemeContext.Consumer> {({theme}) => <Component theme={theme} />} </ThemeContext.Consumer> ); } } return ThemedComponent; }; export default withTheme;
Notice that the Consumer part is similar to the ones before, and the only thing that we added is the
ThemedComponent that wraps it.
But how do we use this HoC for Card?
using the HoC
We could toss the
ThemedCard! since we don't need it anymore! :yes:
Section can now render Card directly
// App.jsx ... // remove/comment out const ThemedCard = () => () const Section = () => <Card />; const Container = () => <Section />; ...
To use the HoC, we only need to call the HoC function
withTheme.
No other changes to our component, and it stays as presentational. We're just 'wrapping' it with out theme context.
export default withTheme(Card)
Here is the new version of
Card:
// Card.jsx import React from 'react'; import withTheme from "./withTheme"; import styles from './styles'; const Card = (props) => ( <div style={styles[props.theme]}> <h1>Card</h1> </div> ) export default withTheme(Card);
Code in part 3 here:
Nice! Now we have a HoC to theme components. We could also easily have a
Avatar or
Button component that has access to the context.
For example:
const Avatar = props => ( <div style={styles[props.theme]}> ... all avatar stuff ) export default withTheme(Avatar);
Access
this.context using
contextType
Here's a little note about how flexible the HoC component can be.
What if, for some reason, you want to have lifecycle methods inside
ThemedComponent ?
// withTheme.js ... class ThemedComponent extends React.Component { componentDidMount() { // NO ACCESS TO context here 😱 console.log(`current theme: ${ this.context.theme }`); // -> ERROR: this.context is undefined ❌ } render() {...} ...
React 16.6 introduced
contextType which allows you to access
this.context to:
- Access context inside the lifecycle methods
- Use context without using the render prop pattern
How? Just declare a static var in the class and assign it to the context object.
// withTheme.js ... class ThemedComponent extends React.Component { static contextType = ThemeContext; componentDidMount() { console.log(`current theme: ${ this.context.theme }`); // -> current theme: dark ✅ } ...
We could also change our Consumer now to a simpler, more familiar syntax.
Instead of
<ThemeContext.Consumer>{theme => <Component theme={theme}>}</ThemedContext.Consumer>, we could do this:
// withTheme.js ... render() { return ( <Component theme={this.context.theme} /> ); }
Code in part 4:
That's more like it. Simple and less confusing brackets.
The only caveat with this is you're limited to subscribing to a single context with this. More on Multiple context here
Adding stuff to the context
As mentioned before, you can structure the data you expose in the context through the Provider any way you want, as long as you access it accordingly in the Consumer.
Let's say you add
themes in the context in the Provider...
Provider
// App.jsx class App extends React.Component { state = { theme: 'dark', themes: ['light', 'dark'], } ...
In the Consumer, you can pass the entire
this.context instead
and you can pass the context as
themeData prop to
<Card />, and access its attributes from Card.
Consumer
// withTheme.js ... render() { return ( <Component themeData={this.context} /> ); } ... // Card.jsx ... const Card = ({themeData}) => ( <div style={styles[themeData.theme]}> <h1>Cards</h1> <p>{themeData.themes.toString()}</p> </div> ) ...
Code in part 5 here:
That's all! I hope that helped clarify why you need context and the different ways of implementing it. Feel free to post any questions, comments or any suggestions.
If you want to learn React by building a mini-Spotify, and you like following slides, check out my React workshop repo
Happy context-ing 🤓!
Discussion
This is so helpful, thanks! | https://practicaldev-herokuapp-com.global.ssl.fastly.net/lennythedev/prop-drilling-react-context-and-higher-order-component-hoc-40m9 | CC-MAIN-2020-45 | refinedweb | 1,363 | 61.02 |
A parking garage charges a $2.00 minimum fee to park for up to 3 hrs. The garag charges an additional .50c per hour for each hour or any part of an hour in excess of 3 hrs. the maximum charge for any given 24 hr period is $10. Assume that no car parks for longer than 24 hours at a time. write a program that will calculate and print the parking charger for each of 8 customers who parked their cars in the garage yesterday. you should enter the hours parked for each customer. The program should print the results in a table and should calculate and print the total of yesterdays receipt. write and use a function named calculateCharges to determine the charge for each customer. The function should accept the number of hrs that a customers vehicle was parked and return the amount owed by the customer.
Im not sure exactly how to make my table work
this is what i have so far
Code:
#include <stdio.h>
#include <math.h>
float calculateCharges(float);
const int NUMBER_OF_CARS= 8;
main()
{
int cars[NUMBER_OF_CARS]= {1,2,3,4,5,6,7,8};
float charges[NUMBER_OF_CARS];
int i;
float hours= 0.0;
float charge= 0.0;
float totalHours= 0.0;
float totalCharges= 0.0;
for(i=0; i<NUMBER_OF_CARS; i++)
{
printf("Enter the hours for car %d:\n", cars[i]);
scanf("%.1f",&hours);
totalHours = totalHours + cars[i];
charge[i] = calculateCharges[i];
totalCharges = totalCharges + charge[i]
printf("\n");
printf("Car\t\t\Hours\t\t\Charge\n");
printf("[i]\t\t\%.1f\t\t\%.2\n", totalHours[i], totalCharges[i]);
}
printf("TOTAL\t\t\%.1f\t\t\%.2f", totalHours, total Charges);
float calculateCharges(float h)
{
const float MINIMUM_CHARGE = 2.0;
const float MAXIMUM_CHARGE = 10.00;
/* the garage charges 2.00 for any amount of time up to 3 hours */
if (h<=3)
return MINIMUM_CHARGE;
/* determine how many hours past 3 hours */
h = h - 3;
/* 0.50 for each hour (or part of an hour) past 3 hours */
float additionalAmount = ceil(h) * 0.50;
float charge = MINIMUM_CHARGE + additionalAmount;
if (charge > MAXIMUM_CHARGE)
return MAXIMUM_CHARGE;
/* determine how many hours past 3 hours */
h = h - 3;
/* 0.50 for each hour (or part of an hour) past 3 hours */
float additionalAmount = ceil(h) * 0.50;
float charge = MINIMUM_CHARGE + additionalAmount;
if (charge > MAXIMUM_CHARGE)
return MAXIMUM_CHARGE;
else
return charge;
} | http://cboard.cprogramming.com/c-programming/132266-help-arrays-loops-printable-thread.html | CC-MAIN-2016-18 | refinedweb | 392 | 68.16 |
Introduction
Today, I am going to talk about memory mapping, a typical topic in operating systems design. I will provide a short summary of memory mapped files in an easy to follow manner. Before we start, I recommend that you get a basic idea about some relevant concepts such as multitasking and paging. Here are few articles that you may need to check out:
Definition - what is memory mapped file?
Memory mapping refers to process ability to access files on disk the same way it accesses dynamic memory. It is obvious that accessing RAM is much faster than accessing disk via read and write system calls. This technique saves user applications IO overhead and buffering but it also has its own drawbacks as we will see later.
How does a memory mapped file work?
Behind the scenes, the operating system utilizes virtual memory techniques to do the trick. The OS splits the memory mapped file into pages (similar to process pages) and loads the requested pages into physical memory on demand. If a process references an address (i.e. location within the file) that does not exists, a page fault occurs and the operating system brings the missing page into memory.
When to use memory mapped file?
Memory mapped files sound like an efficient method to access files on disk. Is it a good option always? That is not necessarily the case. Here are few scenarios where memory mapping is appealing.
- Randomly accessing a huge file once (or a couple of times).
- Loading a small file once then randomly accessing the file frequently.
- Sharing a file or a portion of a file between multiple applications.
- When the file contains data of great importance to the application.
There is a rational behind each example in the list above. If you are curious to know why? please leave a comment in the comments section at the end of this post.
Advantages
Memory mapping is an excellent technique that has various benefits. Examples below.
- Efficiency: when dealing with large files, no need to read the entire file into memory first.
- Fast: accessing virtual memory is much faster than accessing disk.
- Sharing: facilitates data sharing and interprocess communication.
- Simplicity: dealing with memory as opposed to allocating space, copying data and deallocating space.
Disadvantages
Just like any other technique, memory mapping has some drawbacks.
- Memory mapping is generally good for binary files, however reading formatted binary file types with custom headers such as TIFF can be problematic.
- Memory mapping text files is not such an appealing task as it may require proper text handling and conversion.
- The notion that a memory mapped file has always better performance should not be taken for granted. Recall that accessing file in memory may generate a lot of page faults which is bad.
- Memory footprint is larger than that of traditional file IO. In other words, user applications have no control over memory allocation.
- Expanding file size is not easy to implement because a memory mapped file is assumed to be fixed in size.
Difference between memory mapped file and shared memory
- Shared memory is a RAM only form of interprocess communication (IPC) that does not require disk operations.
- Moreover, IPC can be implemented using memory mapped file technique, however it is not as fast as a pure memory only IPC.
Memory mapped file vs named pipe
- Named pipes allow one process to communicate with another process in real time on the same computer or through a network. It is based on client server communication model with a sender and a listener.
- Behind the scenes, named pipes may implement an IPC shared memory.
Python memory mapped file example
Here is a Python code snippet that demonstrates the use of memory mapped files. From the programmer perspective, it is no different than using standard file access calls.
import mmap # Open file.txt for reading in binary mode with open("file.txt", "r+b") as f: # Memory map the entire file (i.e 0 parameter) m = mmap.mmap(f.fileno(), 0) # Read a line just like reading a standard file # You can use other file operations like seek() line = m.readline() # Use slice notation slice = m[:5] # Close map mm.close()
That is it for today. I hope we got the concept of memory mapped file explained. If you have questions or comments, please use the comments section below.
References | http://www.8bitavenue.com/2016/12/memory-mapped-files-in-os/ | CC-MAIN-2017-17 | refinedweb | 729 | 57.77 |
Video¶
The
Video widget is used to display video files and streams.
Depending on your Video core provider, platform, and plugins, you will
be able to play different formats. For example, the pygame video
provider only supports MPEG1 on Linux and OSX. GStreamer is more
versatile, and can read many video containers and codecs such as MKV,
OGV, AVI, MOV, FLV (if the correct gstreamer plugins are installed). Our
VideoBase implementation is used under the
hood.
Video loading is asynchronous - many properties are not available until the video is loaded (when the texture is created):
def on_position_change(instance, value): print('The position in the video is', value) def on_duration_change(instance, value): print('The duration of the video is', value) video = Video(source='PandaSneezes.avi') video.bind( position=on_position_change, duration=on_duration_change )
One can define a preview image which gets displayed until the video is
started/loaded by passing
preview to the constructor:
video = Video( source='PandaSneezes.avi', preview='PandaSneezes_preview.png' )
One can display the placeholder image when the video stops by reacting on eos:
def on_eos_change(self, inst, val): if val and self.preview: self.set_texture_from_resource(self.preview) video.bind(eos=on_eos_change)
- class kivy.uix.video.Video(**kwargs)[source]¶
Bases:
kivy.uix.image.Image
Video class. See module documentation for more information.
- duration¶
Duration of the video. The duration defaults to -1, and is set to a real duration when the video is loaded.
durationis a
NumericPropertyand defaults to -1.
- eos¶
Boolean, indicates whether the video has finished playing or not (reached the end of the stream).
eosis a
BooleanPropertyand defaults to False.
- loaded¶
Boolean, indicates whether the video is loaded and ready for playback or not.
New in version 1.6.0.
loadedis a
BooleanPropertyand defaults to False.
- options¶
Options to pass at Video core object creation.
New in version 1.0.4.
optionsis an
kivy.properties.ObjectPropertyand defaults to {}.
- play¶
Boolean, indicates whether the video is playing or not. You can start/stop the video by setting this property:
# start playing the video at creation video = Video(source='movie.mkv', play=True) # create the video, and start later video = Video(source='movie.mkv') # and later video.play = True
playis a
BooleanPropertyand defaults to False.
- position¶
Position of the video between 0 and
duration. The position defaults to -1 and is set to a real position when the video is loaded.
positionis a
NumericPropertyand defaults to -1.
- preview¶
Filename / source of a preview image displayed before video starts.
previewis a
StringPropertyand defaults to None.
If set, it gets displayed until the video is loaded/started.
New in version 2.1.0.
- seek(percent, precise=True)[source]¶
- Change the position to a percentage (strictly, a proportion)
of duration.
- Parameters
- percent: float or int
Position to seek as a proportion of the total duration, must be between 0-1.
- precise: bool, defaults to True
Precise seeking is slower, but seeks to exact requested percent.
Warning
Calling seek() before the video is loaded has no effect.
New in version 1.2.0.
Changed in version 1.10.1: The precise keyword argument has been added.
- state¶
String, indicates whether to play, pause, or stop the video:
# start playing the video at creation video = Video(source='movie.mkv', state='play') # create the video, and start later video = Video(source='movie.mkv') # and later video.state = 'play'
stateis an
OptionPropertyand defaults to ‘stop’.
- volume¶
Volume of the video, in the range 0-1. 1 means full volume, 0 means mute.
volumeis a
NumericPropertyand defaults to 1. | https://kivy.org/doc/master/api-kivy.uix.video.html | CC-MAIN-2021-39 | refinedweb | 581 | 61.02 |
Red Hat Bugzilla – Bug 150750
.ics file brings Evolution to a swift end
Last modified: 2007-11-30 17:07:06 EST
Description of problem:
Evolution crashes when I attempt to import an ICS file.
Version-Release number of selected component (if applicable):
evolution-1.4.5-12
How reproducible:
Once, haven't reproduced again yet
Steps to Reproduce:
1. Launch Evolution
2. Import, set to single file, leave file type as 'Detect'
3. Attempt to import the Bills.ics file
Actual results:
Evolution segfaults
Expected results:
Evolution displays the contents of the ICS file in the calendar view.
Other notes:
This .ics file was generated by iCal. Not sure if that has anything to do with
the crash, but I thought it was worth mentioning how I generated this file.
FWIW I just now successfully imported the calendar on a machine running rawhide
(evo 2.2, e-d-s 1.2); was promted for file type; chose ics over vcf
Dave, On i386 this does not work either. There is no segfault but the text for
the calendar items does not show in the Day view but the days are bolded in the
numerical calendar pane.
Follow up ... above I was usng automatic and it defaulted to .ics. If I force a
.vcf Evolution crashes.
Created attachment 112111 [details]
Backtrace of Evolution crash
I had to import the .ics file twice as .vcf. The first import errored but did
not crash evolution. The second import did. Also there is no crash if you set
the target of the import to a new calendar. Crashing happens only when tryng to
import the file into the existing default calendar.
Looks like a dup of bug 157352.
Is this fixed with the latest packages? | https://bugzilla.redhat.com/show_bug.cgi?id=150750 | CC-MAIN-2017-43 | refinedweb | 292 | 69.07 |
Hi,
I’m trying to save a document with a table in pdf and word formats, where table has different border widths (by setting lineWidth for all table cell borders). Problem is, that when it is saved as pdf, corners of the thicker borders are “cut”. On the other hand, when exported to word (or html) - corners are not cut.
I was also able to reproduce the same issue by simply loading a word file with LoadAndSaveToDisk class from Aspose.Words Examples (). Word and HTML outputs do not have cut borders, while PDF output has cut borders at the bottom.
public class LoadAndSaveToDisk { public static void main(String[] args) throws Exception { String dataDir = Utils.getDataDir(LoadAndSaveToDisk.class); Document doc = new Document(dataDir + "table_with_custom_border_widths.docx"); doc.save(dataDir + "Pdf Document Out.pdf"); doc.save(dataDir + "Word Document Out.docx"); doc.save(dataDir + "Html Document Out.html"); } }
table_with_custom_border_widths.zip (56.1 KB) | https://forum.aspose.com/t/retain-corners-of-thick-table-borders-during-converting-word-document-docx-to-pdf-using-java/207699 | CC-MAIN-2021-39 | refinedweb | 150 | 58.18 |
hello , does any one know the style or extended style to make the windows xp button styles(bubble style) in win32 api
hello , does any one know the style or extended style to make the windows xp button styles(bubble style) in win32 api
Unfortunately its a little more difficult than just adding a style (which is what I had hoped you could do initialy!). You need to include a windows manifest file as a resource and init the common controls. There is a brief link here describing the process. If you have any other troubles getting it to work, come back and ask.
Last edited by dalek; 05-26-2004 at 03:33 AM.
ok thanks for that.gave me a clear understanding 1 thing.
how do i include this in a C , win32 api program.thanks
Using Windows XP Visual Styles
Perhaps the quickest/shortest route is to link with comctl32.lib, use InitCommonControlsEx and include the manifest file in the same directory as the executable. For example:Build that and call the exe 'manifest_demo.exe' then save the following as manifest_demo.exe.manifest in the same directory:Build that and call the exe 'manifest_demo.exe' then save the following as manifest_demo.exe.manifest in the same directory:Code:#include <windows.h> #include <tchar.h> #if defined __MINGW_H #define _WIN32_IE 0x0400 #endif #include <commctrl.h> /*link with comctl32.lib (-lcomctl32 with DevCpp(MinGW))*/ int WINAPI _tWinMain(HINSTANCE hInstance,HINSTANCE hPrevInstance, LPTSTR lpCmdLine,int nCmdShow) { INITCOMMONCONTROLSEX iccx; iccx.dwSize=sizeof(INITCOMMONCONTROLSEX); iccx.dwICC=0; InitCommonControlsEx(&iccx); MessageBox(0, _T("Don't forget to include your xp manifest\nin the same directory as this exe."), _T("XP Manifest Styles"), MB_OK); return 0; }Code:<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0"> <assemblyIdentity version="1.0.0.0" processorArchitecture="X86" name="CompanyName.ProductName.manifest_demo.exe">
Last edited by Ken Fitlike; 05-26-2004 at 06:14 AM.
CProgramming FAQ
Caution: this person may be a carrier of the misinformation virus.
hmm theres only 1 problem thou.if u dont have the manifest file there it doesnt work
any one know how to fix this?
This is what i do..
1. Create a custom resource called "RT_MANIFEST" without quotes.
2. Name the resource "1" without quotes.
3. Paste in the xml code Ken gave you.
4. Save & Recompile.
You still need to use the common controls as stated in previous posts.
ok im not sure what im doing wrong but i cant get it to work
Paste this into your resource file:
where YourApp.exe.manifest refers to the manifest file you created as per Ken's post. (This is essentially what Marc was describing).where YourApp.exe.manifest refers to the manifest file you created as per Ken's post. (This is essentially what Marc was describing).Code:#ifndef RT_MANIFEST #define RT_MANIFEST 24 #endif #ifndef CREATEPROCESS_MANIFEST_RESOURCE_ID #define CREATEPROCESS_MANIFEST_RESOURCE_ID 1 #endif CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "YourApp.exe.manifest"
ok thanks...only problem now is that lcc-win32 says its impossible to read the rc file
Apparently, lcc does not support RT_MANIFEST. You can grab the free Resource Hacker to add your manifest to the exe.
its not thats its not reading the manifest its that it isnt read the rc files
its wierd never happened before
Hey,
For Starters i'm using Dev-cpp.
I can get the manifest file to work the only problem is that the manifest all ways has to be in teh diretory with the program is there away to make the manifest say become a resourse in the project its self thus being able to chaneg directorys?
Thanks. | https://cboard.cprogramming.com/windows-programming/53322-win32-api-windows-xp-button-styles.html | CC-MAIN-2017-43 | refinedweb | 611 | 50.73 |
The problem I am having is finding a way to write a rule that will be good enough to find a malicious child-process that is multiple levels deep from the parent process.
For example:
I want to be able to create a sysmon related rule that detects when cmd.exe launches a sub-process office process
cmd.exe --> powershell.exe --> winword.exe OR powerpnt.exe OR excel.exe
The issue with sysmon is that I cannot seem to figure out a way to be able to walk up a chain or down a chain of processes and the ParentProcessGUID is only good for 1 level deep. Therefore, I tried to create a search that will look for the child-process and then look for the parent process I am looking for and join them together and possibly bucket them within 1m or 2m since most of the time the executions are very close to the same time. Below is something that I thought may work for some of this, but for whatever reason it does not seem to pull in all host together for this, even if the time is in the right range. If I specify the host name directly in the main search and subsearch, it works fine, but if I do it like below I don't get the intended result, but instead get other systems except the one I want.
index="wineventlog" sourcetype="XmlWinEventLog:Microsoft-Windows-Sysmon/Operational" EventID=1 EventDescription="Process Create" (process=winword.exe OR process=excel.exe OR process=powerpnt.exe) | fields process, parent_process_name, _time, host | join type=inner host max=0 [ search index="wineventlog" sourcetype="XmlWinEventLog:Microsoft-Windows-Sysmon/Operational" EventID=1 EventDescription="Process Create" parent_process_name=cmd.exe | rename process as other_process, parent_process_name as other_parent | fields other_process, other_parent, _time, host ]
I would figure that passing the host into the join command would join together the results from the main search host that has the office processes with the one from the subsearch that has the same host and is looking for cmd.exe. Together I could then use that to make a rule out of it. Is there a better way of doing this? I have been racking my brain around it for awhile now. One level deep is not good enough for detection since a lot of malicious processes can execute sub-processes that need to be accounted for as well. You also do not want a ton of false positives.
Any help on this would be most appreciated!
import splunklib.client as client import splunklib.results as results from time import sleep from datetime import datetime, timedelta import getpass>>" + str(result)
I can't get my original work so I threw this together to show you how to use the Splunk SDK to recursively build descendant process chains from an input ProcessGuid using the Sysmon sourcetype. The final output from the search is an ordered dictionary of all the search fields (all the fields in the table..). You will need to grab the values from these dictionaries to do anything further. Also, to integrate it into Splunk, you'll need to return the results to the search pipeline by using InterSplunk library as well as passing auth into the function - too much to digest right now though.
If you want to time sequence the results sort by RecordID and UtcTime.
Note you must have the splunklib library from the SDK for this to work...
I've done it and you won't be able to do it with a sub-search. Unfortunately Splunk doesn't provide any convenient recursive functionality - you're going need to write a custom command...
I don't have access to the code, but I can walk you through it. You'll need to start digging through the Splunk Python API.
The first thing you'll need to do is pick your target ProcessGuid. I made a workflow action from the event list to call a custom search command that runs in Python, but you can do the same thing (and it's easier) to just use the Python REST API.
It isn't often that an event will have more than one descendant process create. It's also a pretty computationally expensive when they do as you may see 5+ generations and a few thousand processGuid's in the search results. I limit the search window by passing the host and the event time bounding the search with a small time window (maybe an hour).
Sorry I can't just paste the Python (it was a 200 or so lines), but learn the REST API and learn to make a few queries, then just put the recursion in a while loop where you test to see if no more returns are made on the search.
I'm curious to what the python looks like. I have used Splunk's rest API in the past, but it is much easier to see it in the code than to follow all the steps. Could you host it up on some file share like dropbox temporarily so I could download it? I do appreciate the walkthrough and that is a great solution.
I do think that any of the solutions posted so far is going to be best only in responding to alerts already in Splunk ES as notables and not generating notables themselves. This is based on process relationships since that would span everything coming into sysmon over 10 minutes and having to build all of that for every process possibility on each system over 10 minutes could take a longer than desired result. Even if I accelerate it into a data model, it may still be too much computationally to track if the parent process is fairly common.
I use McAfee expert rules to alert on a lot of parent --> child relationships, but they too lack sub-process tracking beyond 1 level deep. Symantec, however, does track it and wish we had it where I work now. Was hoping sysmon could do this much easier. I could always play around with it and see.
I admire that you have been able to implement a method to identify child processes of a selected process within the Splunk UI. Here is my REST-based method to list activities logged by sysmon for a selected process and it's children. Sounds like we apply similar methods and that they could be used by OP in some way to list the kill chain associated with a notable event. | https://community.splunk.com/t5/Splunk-Enterprise-Security/How-do-I-correlate-sysmon-data-for-malicious-child-sub-processes/td-p/456674 | CC-MAIN-2022-27 | refinedweb | 1,089 | 67.89 |
strndup
From cppreference.com
Returns a pointer to a null-terminated byte string, which contains copies of at most
size bytes from the string pointed to by
str1. The space for the new string is obtained as if malloc was called. If the null terminator is not encountered in the first
size bytes, it is appended to the duplicated string.ndup except that it is allowed, but not required to set errno on error.
[edit] Example
Run this code
#include <string.h> #include <stdio.h> #include <stdlib.h> int main(void) { const size_t n = 3; const char *src = "Replica"; char *dup = strndup(src, n); printf("strndup(\"%s\", %lu) == \"%s\"\n", src, n, dup); free(dup); src = "Hi"; dup = strndup(src, n); printf("strndup(\"%s\", %lu) == \"%s\"\n", src, n, dup); free(dup); const char arr[] = {'A','B','C','D'}; // NB: no trailing '\0' dup = strndup(arr, n); printf("strndup({'A','B','C','D'}, %lu) == \"%s\"\n", n, dup); free(dup); }
Output:
strndup("Replica", 3) == "Rep" strndup("Hi", 3) == "Hi" strndup({'A','B','C','D'}, 3) == "ABC" | https://en.cppreference.com/w/c/string/byte/strndup | CC-MAIN-2021-04 | refinedweb | 176 | 72.36 |
Animating with React, Redux, and d3
And now for some pure nerdy fun: A particle generator… or, well, as close as you can get with React and D3. You'd need WebGL for a real particle generator.
We're making tiny circles fly out of your mouse cursor. Works on mobile with your finger, too.
To see the particle generator in full action, go here. Embedded below for your convenience. Github won't let me host different branches, so you'll see the advanced 20,000 particle version from next chapter.
We're using the game loop approach to animation and Redux to store the state tree and drive changes for each frame.
You can see the full code on GitHub. I've merged the SVG and Canvas branches. Redux part is the same, some parameters differ. We're focusing on the Redux part because that's what's new.
It's going to be great.
Code in this example uses the
.jsx file extension. I originally wrote
it back when that was still a thing, and while I did update everything to React
16+, I felt that changing filenames was unnecessary.
Here's how it works
We use React to render everything: the page, the SVG element, the particles inside.,, as well. This lets us treat animation as data transformations. I'll show you what that. Just like the game loop example from before.
Some basic terminology
We're about to throw around some terms. You'll understand what they mean in detail after this chapter.
Until then, here's a quick glossary so you don't feel lost:
The store, or the state, is Redux state. Held globally and shared by all components. It's like the App local state from earlier chapters.
Actions are packets of information that tell us what happened.
Reducers are functions that take the current state and an action, and use that information to generate a new state.
Got it? No worries. You will soon 😃
3 presentation components
We start with the presentation components because they're the simplest. To render a collection of particles, we need:
- a stateless
Particle
- a stateless
Particles
- a class-based
App
None of them contain state, but
App has to be a class-based component so that
we can use
componentDidMount. We need it to attach D3 event listeners.
Particle
The
Particle component is a circle. It looks like this:
// src/components/Particles/Particle.jsximport React from "react"const Particle = ({ x, y }) => <circle cx={x} cy={y}export default Particle
It takes
x and
y coordinates and returns an SVG circle.
Particles
The
Particles component isn't much smarter – it returns a list of circles
wrapped in a grouping element, like this:
// src/components/Particles/index.jsximport React from "react"import Particle from "./Particle"const Particles = ({ particles }) => (<g>{particles.map((particle) => (<Particle key={particle.id} {...particle} />))}</g>)export default Particles
Walk through the array of particles, render a Particle component for each. Declarative rendering that you've seen before 😃
We can take an array of
{id, x, y} objects and render SVG circles. Now comes
our first fun component: the
App.
App
App takes care of rendering the scene and attaching d3 event listeners. It
gets actions via props and ties them to mouse events. You can think of actions
as callbacks that work on the global data store directly. No need to pass them
through many levels of props.
The rendering part looks like this:
// src/components/index.jsximport React, { Component } from "react"import { select as d3Select, mouse as d3Mouse, touches as d3Touches } from "d3"import Particles from "./Particles"import Footer from "./Footer"import Header from "./Header"class App extends Component {// ..render() {return (<divonMouseDown={(e) => this.props.startTicker()}style={{ overflow: "hidden" }}><Header /><svgwidth={this.props.svgWidth}height={this.props.svgHeight}ref="svg"style={{ background: "rgba(124, 224, 249, .3)" }}><Particles particles={this.props.particles} /></svg><Footer N={this.props.particles.length} /></div>)}}export default App
There's more going on, but the gist is that we return a
<div> with a
Header, a
Footer, and an
<svg>. Inside
<svg>, we use
Particles to
render many circles. The Header and Footer components are just some helpful some circles. React takes care of the rest.
Oh, and we call
startTicker() when a user clicks on our scene. No reason to
have the clock running before any particles exist.
D3 event listeners
To let users generate particles, we have to wire up some functions in
componentDidMount. That looks like this:
// src/components/index.jsxclass App extends Component {svgWrap = React.createRef();componentDidMount() {let svg = d3Select(this.svgWrap.current)Mouse(this.svgWrap.current);this.props.updateMousePos(x, y);}updateTouchPos() {let [x, y] = d3Touches(this.svgWrap.current)[0];this.props.updateMousePos(x, y);}
There are several events we take into account:
mousedownand
touchstartturn on particle generation
mousemoveand
touchmoveupdate the mouse location
mouseup,
touchend, and
mouseleaveturn off particle generation
Inside our event callbacks, we use
updateMousePos and
updateTouchPos to
update Redux state. They use
d3Mouse and
d3Touches to get
(x, y)
coordinates for new particles relative to our SVG element and call Redux
actions passed-in via props. The particle generation step uses this data as
each particle's initial position.
You'll see that in the next section. I agree, it smells kind of convoluted, but it's for good reason: We need a reference to a mouse event to get the cursor position, and we want to decouple particle generation from event handling.
Remember, React isn't smart enough to figure out mouse position relative to our drawing area. React knows that we clicked a DOM node. D3 does some magic to find exact coordinates.
Touch events return lists of coordinates. One for each finger. We use only the first coordinate because shooting particles out of multiple fingers would make this example too hard.
That's it for rendering and user events. 107 lines of code.
6 Redux Actions
Redux actions are a fancy way of saying "Yo, a thing happened!". They're functions you call to get structured metadata that's passed into Redux reducers.
Our particle generator uses 6 actions:
tickTimesteps our animation to the next frame
tickerStartedfires when everything begins
startParticlesfires when we hold down the mouse
stopParticlesfires when we release
updateMousePoskeeps mouse position saved in state
resizeScreensaves new screen size so we know where edges lie
Our actions look something like this:
export function updateMousePos(x, y) {return {type: UPDATE_MOUSE_POS,x: x,y: y,}}
A function that accepts params and returns an object with a type and meta data. Technically this is an action generator and the object is an action, but that distinction has long since been lost in the community.
Actions must have a
type. Reducers use the type to decide what to do. The
rest is optional.
You can see all the actions on GitHub.
I find this to be the least elegant part of Redux. Makes sense in large applications, but way too convoluted for small apps. Simpler alternatives exist like doing it yourself with React Context.
1 Container component
Containers are React components that talk to the Redux data store.
You can think of presentation components as templates that render stuff and containers as smart-ish views that talk to controllers. Or maybe they're the controllers.
Sometimes it's hard to tell. In theory presentation components render and don't think, containers communicate and don't render. Redux reducers and actions do the thinking.
I'm not sure this separation is necessary in small projects.
Maintaining it can be awkward and sometimes cumbersome in mid-size projects, but I'm sure it makes total sense at Facebook scale. We're using it in this project because the community has decided that's the way to go.
We use the idiomatic
connect() approach. Like this:
// src/containers/AppContainer.jsximport { connect } from "react-redux"import React, { Component } from "react"import * as d3 from "d3"import App from "../components"import {tickTime,tickerStarted,startParticles,stopParticles,updateMousePos,} from "../actions"class AppContainer extends Component {startTicker = () => {const { isTickerStarted } = this.propsif (!isTickerStarted) {console.log("Starting ticker")this.props.tickerStarted()d3.timer(this.props.tickTime)}}render() {const { svgWidth, svgHeight, particles } = this.propsreturn (<AppsvgWidth={svgWidth}svgHeight={svgHeight}particles={particles}startTicker={this.startTicker}startParticles={this.props.startParticles}stopParticles={this.props.stopParticles}updateMousePos={this.props.updateMousePos}/>)}}const)
I love the smell of boilerplate in the morning. :nose:
We import dependencies and define
AppContainer as a class-based React
Component so we have somewhere to put the D3 interval. The render method
outputs our
<App> component using a bunch of props to pass relevant actions
and values.
The
startTicker method is a callback we pass into App. It runs on first click
and starts the D3 interval if necessary. Each interval iteration triggers the
tickTime action.
AppContainer talks to the store
// src/containers/AppContainer.jsxconst)
We're using the
connect() idiom to connect our AppContainer to the Redux
store. It's a higher order component that handles all the details of connection
to the store and staying in sync.
We pass two arguments into connect. This returns a higher order component function, which we wrap around AppContainer.
The first argument is mapStateToProps. It accepts current state as an argument, which we immediately deconstruct into interesting parts, and returns a key:value dictionary. Each key becomes a component prop with the corresponding value.
You'd often use this opportunity to run ad-hoc calculations, or combine parts of state into single props. No need for that in our case, just pass it through.
Dispatching actions
mapDispatchToProps is a dictionary that maps props to actions. Each prop
turns into an action generator wrapped in a
store.dispatch() call. To fire an
action inside a component we just call the function in that prop.
But Swiz, we're not writing key:value dictionaries, we're just listing stuff!
That's a syntax supported in most modern JavaScript environments, called object
literal property value shorthand. Our build system expands that
mapDispatchToProps dictionary into something like this:
const mapDispatchToProps = {tickTime: tickTime,tickerStarted: tickerStarted,startParticles: startParticles,stopParticles: stopParticles,updateMousePos: updateMousePos,}
And you thought previous code had a lot of boilerplate ... imagine if this was how you'd do it in real life :stuck_out_tongue:
connect wraps each of these action generators in
store.dispatch() calls.
You can pass the resulting function into any component and fire actions by
calling that method.
The Redux loop
To make a change therefore, a Redux loop unfolds:
- Call our action triggerer, passed in through props
- Calls the generator, gets a
{type: ...}object
- Dispatches that object on the store
- Redux calls the reducer
- Reducer creates new state
- Store updates triggering React's engine to flow updates through the props
So that's the container. 71 lines of boilerplate pretty code.
The remaining piece of the puzzle is our reducer. Two reducers in fact.
2 Redux Reducers
With the actions firing and the drawing done, it's time to look at the business logic of our particle generator. We'll get it done in just 33 lines of code and some change.
Well, it's a bunch of change. But the 33 lines that make up
CREATE_PARTICLES
and
TIME_TICK changes are the most interesting. The rest just flips various
flags.
All our logic and physics goes in the reducer.
Dan Abramov says to think of
reducers as the function you'd put in
.reduce(). Given a state and a set of
changes, how do I create the new state?
A "sum numbers" example would look like this:
let sum = [1, 2, 3, 4].reduce((sum, n) => sum + n, 0)
For each number, take the previous sum and add the number.
Our particle generator is a more advanced version of the same concept: Takes current application state, incorporates an action, and returns new application state.
Start with a default state and some D3 random number helpers.
import { randomNormal } from "d3";const Gravity = 0.5,randNormal = randomNormal(0.3, 2),randNormal2 = randomNormal(0.5, 1.:sunglasses:;const initialState = {particles: [],particleIndex: 0,particlesPerTick: 30,svgWidth: 800,svgHeight: 600,isTickerStarted: false,generateParticles: false,mousePos: [null, null],lastFrameTime: null};
Using D3's
randomNormal random number generator creates a better random
distribution than using JavaScript's own
Math.random. The rest is a bunch of
default state 👇
particlesholds an array of particles to draw
particleIndexdefines the ID of the next generated particle
particlesPerTickdefines how many particles we create on each requestAnimationFrame
svgWidthis the width of our drawing area
svgHeighis the height
isTickerStartedspecifies whether the animation is running
generateParticlesturns particle generation on and off
mousePosdefines the origination point for new particles
lastFrameTimehelps us compensate for dropped frames
To manipulate all this state, we use two reducers and manually combine them.
Redux does come with a
combineReducers function, but I wanted to keep our
state flat and that doesn't fit
combineReducers's view of how life should
work.
// src/reducers/index.js// Manually combineReducersexport default function (state = initialState, action) {return {...appReducer(state, action),...particlesReducer(state, action),}}
This is our reducer. It takes current
state, sets it to
initialState if
undefined, and an action. To create new state, it spreads the object returned
from
appReducer and from
particlesReducer into a new object. You can
combine as many reducers as you want in this way.
The usual
combineReducers approach leads to nested hierarchical state. That
often works great, but I wanted to keep our state flat.
Lesson here is that there are no rules. You can make your reducers whatever you want. Combine them whichever way fits your use case. As long as you take a state object and an action and return a new state object.
appReducer will handle the constants and booleans and drive the metadata for
our animation.
particlesReducer will do the hard work of generating and
animating particles.
Driving the basics with appReducer
Our
appReducer handles the boring actions with a big switch statement. These
are common in the Redux world. They help us decide what to do based on action
type.
// src/reducers/index.jsfunction appReducer(state, action) {switch (action.type) {case "TICKER_STARTED":return Object.assign({}, state, {isTickerStarted: true,lastFrameTime: new Date(),})case "START_PARTICLES":return Object.assign({}, state, {generateParticles: true,})case "STOP_PARTICLES":return Object.assign({}, state, {generateParticles: false,})case "UPDATE_MOUSE_POS":return Object.assign({}, state, {mousePos: [action.x, action.y],})case "RESIZE_SCREEN":return Object.assign({}, state, {svgWidth: action.width,svgHeight: action.height,})default:return state}}
Gotta love that boilerplate :stuck_out_tongue:
Even though we're only changing values of boolean flags and two-digit arrays, we have to create a new state. Redux relies on application state being immutable.
Well, JavaScript doesn't have real immutability. We pretend and make sure to never change state without making a new copy first. There are libraries that give you proper immutable data structures, but that's a whole different course.
We use
Object.assign({}, ... to create a new empty object, fill it with the
current state, then overwrite specific values with new ones. This is fast
enough even with large state trees thanks to modern JavaScript engines.
Note that when a reducer doesn't recognize an action, it has to return the same state it received. Otherwise you end up wiping state. 😅
So that's the boilerplatey state updates. Manages starting and stopping the animation, flipping the particle generation switch, and resizing our viewport.
The fun stuff happens in
particleReducer.
Driving particles with particleReducer
Our particles live in an array. Each particle has an id, a position, and a vector. That tells us where to draw the particle and how to move it to its future position.
On each tick of the animation we have to:
- Generate new particles
- Remove particles outside the viewport
- Move every particle by its vector
We can do all that in one big reducer, like this:
// src/reducers/index.jsfunction particlesReducer(state, action) {switch (action.type) {case "TIME_TICK":let {svgWidth,svgHeight,lastFrameTime,generateParticles,particlesPerTick,particleIndex,mousePos,} = state,newFrameTime = new Date(),multiplier = (newFrameTime - lastFrameTime) / (1000 / 60),newParticles = state.particles.slice(0)if (generateParticles) {for (let i = 0; i < particlesPerTick; i++) {let particle = {id: state.particleIndex + i,x: mousePos[0],y: mousePos[1],}particle.vector = [particle.id % 2 ? -randNormal() : randNormal(),-randNormal2() * 3.3,]newParticles.unshift(particle)}particleIndex = particleIndex + particlesPerTick + 1}let movedParticles = newParticles.filter((p) => {return !(p.y > svgHeight || p.x < 0 || p.x > svgWidth)}).map((p) => {let [vx, vy] = p.vectorp.x += vx * multiplierp.y += vy * multiplierp.vector[1] += Gravity * multiplierreturn p})return {particles: movedParticles,lastFrameTime: new Date(),particleIndex,}default:return {particles: state.particles,lastFrameTime: state.lastFrameTime,particleIndex: state.particleIndex,}}}
That's a lot of code, I know. Let me explain 😃
The first part takes important values out of
state, calculates the dropped
frame multiplier, and makes a new copy of the particles array with
.slice(0).
That was the fastest way I could find.
Then we generate new particles.
We loop through
particlesPerTick particles, create them at
mousePos
coordinates, and insert at the beginning of the array. In my tests that
performed best. Particles get random movement vectors.
This randomness is a Redux faux pas. Reducers are supposed to be functionally pure: produce the same result every time they are called with the same argument values. Randomness is impure.
We don't need our particle vectors to be deterministic, so I think this is fine. Let's say our universe is stochastic instead 😄
{aside} Stochastic means that our universe/physic simulation is governed by probabilities. You can still model such a universe and reason about its behavior. A lot of real world physics is stochastic in nature. {/aside}
We now have an array full of old and new particles. We remove all out-of-bounds
particles with a
filter, then walk through what's left to move each particle
by its vector.
To simulate gravity, we update vectors' vertical component using our
Gravity
constant. That makes particles fall down faster and faster creating a nice
parabola.
Our reducer is done. Our particle generator works. Our thing animates smoothly. \o/
What we learned
Building a particle generator in React and Redux, we made three important discoveries:
- Redux is much faster than you'd think. Creating a new copy of the state tree on each animation loop sounds crazy, but it works. Most of our code creates shallow copies, which explains the speed.
- Adding to JavaScript arrays is slow. Once we hit about 300 particles, adding new ones becomes making shallow copies of big arrays and moving existing SVG nodes around is faster than adding new DOM nodes and array elements. Here's a gif
There you go: Animating with React, Redux, and D3. Kind of a new superpower 😉
Here's the recap:
- React handles rendering
- D3 calculates stuff, detects mouse positions
- Redux handles state
- element coordinates are state
- change coordinates on every
requestAnimationFrame
- animation!
Now let's render to canvas and push this sucker to 20,000 smoothly animated elements. Even on a mobile phone. | https://reactfordataviz.com/animation/redux-animation/ | CC-MAIN-2022-40 | refinedweb | 3,144 | 50.73 |
The Eclipse code that uses the XEmbeddedFrame is most likely the SWT_AWT bridge. This class is a platform-dependent hack that's used to embed AWT/Swing within SWT apps, and vice versa. See: It'd be interesting to see how Classpath could provide APIs that allow similar function to SWT - as this function can not be achived using the public Java api. - Jeff Myers On 11/22/05, Meskauskas Audrius <address@hidden> wrote: > Egon Willighagen wrote: > > >Not implemented [need JDK 1.5 or greater] (java.lang.ClassNotFoundException: > >sun/awt/X11/XEmbeddedFrame) > > > > > > > The problem is, the application is using the proprietary Sun class from > the protected sun.* namespace. The Sun's license does not permit to add > classes from this package. Also, the class is probably totally > undocumented and we have no right to look into the Sun sources doing > "exactly the same". If this does not come from Eclipse, we need can > rewrite the calling code. > > Best wishes > Audrius | http://lists.gnu.org/archive/html/classpath/2005-11/msg00167.html | CC-MAIN-2015-18 | refinedweb | 160 | 65.12 |
:
try { int age = 39; String poetName = "dylan thomas"; CallableStatement proc = connection.prepareCall("{ call set_death_age(?, ?) }"); proc.setString(1, poetName); proc.setInt(2, age); cs.execute(); } catch (SQLException e) { // .... }
The string passed to the
prepareCall method is the procedure
call specification. It specifies the name of the procedure to call and a
? for each parameter you need to specify..
Stored procedures can return values, so the
CallableStatement
class has methods like
getResultSet to retrieve return values.
When a procedure returns a value, you must tell the JDBC driver what SQL type
the value will be, with the
registerOutParameter method. You must
also change the procedure call specification to indicate that the procedure
returns a value.
Here's a follow on from our earlier example. This time we're asking how old
Dylan Thomas was when he passed away. This time, the stored procedure is in
PostgreSQL's
pl/pgsql:
create function snuffed_it_when (VARCHAR) returns integer ' declare poet_id NUMBER; poet_age NUMBER; begin -- first get the id associated with the poet. SELECT id INTO poet_id FROM poets WHERE name = $1; -- get and return the age. SELECT age INTO poet_age FROM deaths WHERE mort_id = poet_id; return age; end; ' language 'pl/pgsql';
As an aside, note that the
pl/pgsql parameter names are referred to by the
$n syntax used in Unix and DOS scripts. Also note the
embedded comments; this is another advantage over Java. Writing such comments
in Java is possible, of course, but they often look messy and disjointed from
the SQL text, which has to be embedded in Java
Strings.
Here's the Java code to call the procedure:
connection.setAutoCommit(false); CallableStatement proc = connection.prepareCall("{ ? = call snuffed_it_when(?) }"); proc.registerOutParameter(1, Types.INTEGER); proc.setString(2, poetName); cs.execute(); int age = proc.getInt(2);
What happens if you specify the return type incorrectly? Well, you get a
RuntimeException when the procedure is called, just as you do when
you use a wrong type method in a
ResultSet operation.
Many people's knowledge of stored procedures seems to end with what we've discussed. If that's all there was to stored procedures, they wouldn't be a viable replacement for other remote execution mechanisms. Stored procedures are much more powerful.
When you execute a SQL query, the DBMS creates a database object called a
cursor, which is used to iterate over each row returned from a query. A
ResultSet is a representation of a cursor at a point in time.
That's why, without buffering or specific database support, you can only go
forward through a
ResultSet.
Some DBMSs allow you to return a reference to a cursor from a stored
procedure call. JDBC does not support this, but the JDBC drivers from Oracle,
PostgreSQL, and DB2 all support turning the pointer to the cursor into a
ResultSet.
Consider listing all of the poets who never made it to retirement age. Here's a
procedure that does that and returns the open cursor, again in PostgreSQL's
pl/pgsql language:
create procedure list_early_deaths () return refcursor as ' declare toesup refcursor; begin open toesup for SELECT poets.name, deaths.age FROM poets, deaths -- all entries in deaths are for poets. -- but the table might become generic. WHERE poets.id = deaths.mort_id AND deaths.age < 60; return toesup; end; ' language 'plpgsql';
Here's a Java method that calls the procedure and outputs the rows to a
PrintWriter:
static void sendEarlyDeaths(PrintWriter out) { Connection con = null; CallableStatement toesUp = null; try { con = ConnectionPool.getConnection(); // PostgreSQL needs a transaction to do this... con.setAutoCommit(false); // Setup the call.); out.println(name + " was " + age + " years old."); } rs.close(); } catch (SQLException e) { // We should protect these calls. toesUp.close(); con.close(); } }
Because returning cursors from procedures is not directly supported by JDBC,
we use
Types.OTHER to declare the return type of the procedure and
then cast from the call to
getObject().
The Java method that calls the procedure is a good example of mapping.
Mapping is a way of abstracting the operations on a set. Instead of returning
the set from this procedure, we can pass in the operation to perform. In this
case, the operation is to print the
ResultSet to an output stream.
This is such a common example it was worth illustrating, but here's another
Java method that calls the same procedure:
public class ProcessPoetDeaths { public abstract void sendDeath(String name, int age); } static void mapEarlyDeaths(ProcessPoetDeaths mapper) { Connection con = null; CallableStatement toesUp = null; try { con = ConnectionPool.getConnection(); con.setAutoCommit(false);); mapper.sendDeath(name, age); } rs.close(); } catch (SQLException e) { // We should protect these calls. toesUp.close(); con.close(); } }
This allows arbitrary operations to be performed on the
ResultSet data without having to change or duplicate the method
that gets the
ResultSet! If we want we can rewrite the
sendEarlyDeaths method:
static void sendEarlyDeaths(final PrintWriter out) { ProcessPoetDeaths myMapper = new ProcessPoetDeaths() { public void sendDeath(String name, int age) { out.println(name + " was " + age + " years old."); } }; mapEarlyDeaths(myMapper); }
This method calls
mapEarlyDeaths with an anonymous instance of
the class
ProcessPoetDeaths. This class instance has an
implementation of the
sendDeath method, which writes to the output
stream in the same way as our previous example. Of course, this technique
isn't specific to stored procedures, but combined with stored procedures that
return
ResultSets, it is a powerful tool.
Stored procedures can help achieve logical separation in your code, which is nearly always a good thing. The benefits of this separation are:
Not all databases support stored procedures, but there are many good implementations, both free/open source and non-free, so portability probably isn't an issue. Oracle, PostgreSQL, and DB2 have very similar stored procedure languages that are well supported by online communities.
Stored procedure tools are widespread. There are editors, debuggers, and IDEs
such as TOAD or TORA that provide great environments for writing and
maintaining PL/SQL or
pl/pgsql.
Stored procedures do add overhead to your code, but they add much less overhead than most application servers. If your code is complex enough to need a DBMS, I wholly recommend adopting the stored procedure approach.
Nic Ferrier is an independent software consultant specializing in web applications.
Return to ONJava.com. | http://www.onlamp.com/lpt/a/4082 | CC-MAIN-2014-42 | refinedweb | 1,027 | 56.76 |
2006
Body type not supported by Remote Host - text/plain
Posted by benblackmore NO[at]SPAM nospam.postalias at 5/31/2006 12:00:00 AM
Hi, We are running Windows 2003 server SP1 with ISA 2004 SP2 as our edge firewall, this is also running IIS6/SMTP as a relay, which then sends email to our internal mail server, this is running Windows 2003 Server SP1 & Exchange 2003 SP2. Yesterday I placed an order for some memory with ...
more >>
Mail stays in queue
Posted by mrecomm101 at 5/30/2006 6:17:02 AM
In my SMTP setup, I have a Local (Default) which is the machine name. And I have a Local (alias) which is the domain.com name I use as my "send from" address. Mail is staying in the queue. Any thoughts as to how I should setup SMTP and/or my DNS to support sending mail out with the originating...
more >>
Metabase Update Warnings
Posted by Nicolas Macarez at 5/25/2006 10:15:08 PM
My Exchange Server 2003 SP2 (on W2K3 Server SP1) is working fine. However, I had to remove/reinstall IIS 6.0 after an issue withOWA. And now, I have my event log populated with this warning every 15 minutes: ---------- Event Type: Warning Event Source: MSExchangeMU Event Category: General ...
more >>
Security in SMTP
Posted by aboni at 5/24/2006 5:44:57 PM
Hi! I'm using a POP3 service and SMTP Service of Windows 2003 server to = setup a small Mail Server Enviroment. In my "Default SMTP Virtual Server" -> Properties -> Access -> = Authentication I need to allow "Anonymous Acces". If I don't do that, = people can't send me mail's. My question i...
more >>
what is the way to monitor SMTP? is sending email directly to remote SMTPgood or not?
Posted by davidw at 5/22/2006 11:13:14 PM
Hi, I am developing a email sending management system, I need monitor if email seond out sucessful, if user receive it and if they read it. How can I implement those functions? I read you can send email to remote SMTP, is it good or bad? why? thanks! ...
more >>
Forcing a different SMTP server for mail delivery to an external domain
Posted by autovelox NO[at]SPAM gmail.com at 5/22/2006 2:22:14 AM
Hello, is there a way to force IIS SMTP service to use a particular SMTP server for an external domain that isn't the one listed as MX record? For example, let's say that I need to send a mail to a recipient at 'domain.com', that has 'mail.domain.com' (1.2.3.4) listed as MX record: is there a ...
more >>
Cant recieve mail other than Outlook test
Posted by Hareth at 5/19/2006 6:20:15 PM
prob: i can send mail but i cant recieve mail! smtp & pop wiondows 2003 auth user can relay when i use outlook to test, it addeds the test mail to my inbox, so that works, but i still cant recieve any other mail to that inbox... any other test i can do? any links that can help?...
more >>
SMTP: Mail not flowing
Posted by Douglas G. Walker at 5/17/2006 11:18:02 AM
I have a win2003 server configured to deliver mail addressed to our domain to an Exchange 2003 server. All other email goes out to the rest of the world. Everything works fine but at least once a day (or more) mail destined for Exchange backs up in the queue. Mail to the rest of the world i...
more >>
Don't see what you're looking for? Search DevelopmentNow.com.
problems with testing IIS SMTP
Posted by Thomas at 5/17/2006 10:23:56 AM
Hi, I'm setting up a W2K3 web server that will also send out emails using the IIS SMTP. I was testing the SMTP using TELNET in the server and here's the message I got: -------------------------------------------------------------------------------------------- 220 Daedalus Microsoft ES...
more >>
command line mail
Posted by BFH at 5/17/2006 7:06:02 AM
We have several functions which could use a nice, easy command-line e-mail tool that would relay a short e-mail through the IIS SMTP server. For instance- we run a script nightly to move some files off the server. In UNIX-land, we would finish with "mailx -s "it's finished" recipient@doma...
more >>
Badmails not being created
Posted by Francisco Amaro at 5/16/2006 10:45:11 AM
My SMTP server has stopped generating badmail files. I have moved the badmail folder to a different directory and even tried to create a new SMTP server but still I get no badmails. Sending the mails themselves is working fine and I am getting Bounce Back reports to the "From" address. Un...
more >>
Performance and monitoring
Posted by Andrea A at 5/14/2006 9:42:11 PM
Hi all, I need to install a win2003 Web Edition + SMTP for relaying an huge mailing list outbound. Can you tell me which type of performance will I receive from a Xeon 3Ghz , 2 GB RAm and SCSI disks? Is there a software (free) for monitoring the performance? thanks, a ...
more >>
SMTP error, semaphore timeout period
Posted by Thomas at 5/12/2006 3:21:58 PM
Hi, I'm getting this error from my Web server running Win2003. Message delivery to the host 'XXX.XXX.XX.XXX' failed while delivering to the remote domain 'aol.com' for the following reason: The semaphore timeout period has expired. The SMTP queue is jammed with outgoing mails. The SM...
more >>
Server 2003 Built in Mail blocking attachments
Posted by Daniel Dayon at 5/12/2006 12:45:10 PM a...
more >>
Mail Server blocking certain attachments?
Posted by Mio at 5/12/2006 11:42:02 AM ...
more >>
Smtp Backup
Posted by Kris at 5/11/2006 8:41:42 PM
I am getting ready for another Hurricane season in south Louisiana and would like to use the smtp service on windows 2k3 as a backup to my exchange server. I have purchased a new server and have it stored in a co-lo. Can someone explain (in detail or via a KB/white paper) how to set the smtp...
more >>
Still having problem to deliver email to Hotmail.com
Posted by Kane at 5/10/2006 10:54:49 AM
After I contact my ISP, we have done something on reverse dns but I still have no luck to send email to hotmail.com, videotron.ca, and the sympatico.ca, etc. It is rejected by them oftern. This is the error message when I used SMTPDIAG to diagnose the problem. Error: Expected "250". Serv...
more >>
System.Web.Mail and Virtual SMTP Server
Posted by Nidhee Pathak at 5/9/2006 7:36:36 AM
Hi, I am not able to send out emails through a windows service using the System.Web.Mail namespace. When I use smtpauthenticate = 1 or 2, I get an exception {"The message could not be sent to the SMTP server. The transport error code was 0x80040217. The server response was not available\r\n" ...
more >>
Emails to domains are stuck in SMTP queue (mainly hotmail and msn)
Posted by Toni P. at 5/8/2006 9:16:02 AM
We have had a problem for the past week with sending emails to hotmail and msn email address mainly. We have fixed DNS problems and rebooted the Exchange 2003 server (v6.5.6944.0) and as of Friday afternoon, the messages went through. Now they are stuck again. I have a feeling that when...
more >>
Local SMTP server instead of my ISP:s???
Posted by Bo Berglund at 5/5/2006 7:16:56 PM
I have run into a problem with my ISP's SMTP server in that they have started to do content filtering on *outgoing* email! They actually block all email going out that contain attached files of type .exe ..com .vbs, .pif, .scr .bat .cmd .com .mim .b64 .bhx .hqx .xxe .uu .uue And it does not ma...
more >>
Problems with POP3 Service
Posted by Vittorio Pavesi at 5/2/2006 4:45:49 PM
Hello, I've a Pop3 service using Active Directory authentication working properly with all the account I created manually with POP3 Service console. Now I would like to create some mailbox for already existing account (e.g. Administrator); if I create the mailbox without creating the user ...
more >>
·
·
groups
Questions? Comments? Contact the
d
n | http://www.developmentnow.com/g/92_2006_5_0_0_0/inetserver-iis-smtp-nntp.htm | crawl-001 | refinedweb | 1,434 | 72.76 |
Many developers like to play computer games. They entertain us and help reduce the stress caused by our jobs. Have you ever wanted to create your own version of a computer game? I have. This Java Tech article begins a two-part series on developing two versions of an intelligent computer game, Nim.
In this article, you learn how to play Nim, and discover tools for creating an intelligent computer player. In the next article, you apply those tools to the creation of that player, while building console and GUI Nim games. As you create the GUI version, you'll examine a technique for dragging and dropping game objects.
The game of Nim typically involves two players and a pile of matches, stones, marbles, or some other kind of objects. Each player alternately makes a move by taking one, two, or three objects from the pile. The player who takes the last object(s) loses -- and the other player wins. For example, suppose there's a pile of five matches. Player A takes two matches, leaving three. Player B then takes two matches, leaving one. Player A must take the final match, and loses. Player B wins.
Note: The paragraph above describes one way to play Nim; I use that technique in this article. To learn about other ways to play Nim, and to find out where that name comes from, consult the Wikipedia entry for Nim.
We could create a Nim computer game that requires two human players. However, if one player was absent, the game would certainly lose its appeal. To solve that problem, we will design a computer player to challenge the human player. In a nutshell, the computer player will be intelligent.
How do we create an intelligent computer player? For starters, we need to know a little game theory. According to game theory, Nim is an example of a zero-sum game of perfect information. (Chess, tic-tac-toe, Othello, and checkers are other examples.) "Zero-sum" means that the interests of the players are exactly opposed. Regardless of the game's outcome, the winnings of one player are exactly balanced by the losses of the other(s). For example, only one player wins and only one player loses in a two-player Nim game. "Perfect information" means that, at every move, each player knows all of the moves that have already been made. For example, each player in a two-player Nim game knows all moves made by the other player, along with the player's own moves.
Zero-sum games of perfect information imply that there exists a best strategy for each player, to help that player win or to minimize that player's loss. A pair of tools help intelligent computer players find that best strategy: game trees and the minimax algorithm.
A game tree describes all possible moves, via its branches, and resulting game configurations, via its nodes, in a two-player game. The root node represents the initial game configuration and the leaf nodes represent the terminal configurations: win, lose, or draw. There is only one terminal configuration in Nim -- no matches are left in the pile. That configuration represents a win for Player A if Player B makes the last move, or a win for Player B if Player A makes the last move. Figure 1 reveals a game tree for a two-player Nim game, with an initial game configuration specifying four matches.
Figure 1. Game tree for a two-player Nim game, with an initial pile of four matches
In Figure 1, square pink nodes represent Player A, round green nodes represent Player B, and triangular blue nodes represent the terminal configuration -- a win for Player A or Player B, depending on the parent node (green or pink, respectively). Each branch has a numeric label that indicates how many matches have been taken from the pile, and each node has a numeric label indicating how many matches remain in the pile. The pink square node with numeric label 4 is the root node, and indicates that the pile initially contains four matches and that Player A makes the first move.
Suppose Player A takes one match from the pile. The game tree displays this move via the branch (with label 1) from the root node to the Player B node with the 3 label. Now suppose Player B counters Player A's move by taking two matches from the pile. The game tree reveals this move via the branch (with label 2) from the Player B node with the 3 label to the Player A node with label 1. Player A has no choice but to take the final match, and Player B wins. The game tree presents this move via the branch (labeled 1) from the Player A node with label 1 to the terminal configuration node directly below.
We can easily create a game tree that completely describes a Nim game, with an initial game configuration that specifies n matches. To accomplish that task, we use both a Node class and a recursive game-tree-building method. The Node class appears below:
Node
class Node
{
int nmatches; // Number of matches remaining
// after a move to this Node
// from the parent Node.
char player; // Game configuration from which
// player (A - player A, B -
// player B) makes a move.
Node left; // Link to left child Node -- a
// move is made to left Node
// when 1 match is taken. (This
// link is only null when the
// current Node is a leaf.)
Node center; // Link to center child Node --
// a move is made to this Node
// when 2 matches are taken.
// (This link may be null, even
// if the current Node is not a
// leaf.)
Node right; // Link to right child Node -- a
// move is made to this Node
// when three matches are taken.
// (This link may be null, even
// if the current Node is not a
// leaf.)
}
Each Node object describes a game configuration in terms of the number of matches left on the pile (nmatches), the player whose turn it is to make the next move (player), and links to the left, center, and right immediate child Nodes. The following recursive buildGameTree method combines Node objects into a game tree:
nmatches
player
left
center
right
buildGameTree
static Node buildGameTree (int nmatches,
char player)
{
Node n = new Node ();
n.nmatches = nmatches;
n.player = player;
if (nmatches >= 1)
n.left = buildGameTree (nmatches-1,
(player == 'A')
? 'B' : 'A');
if (nmatches >= 2)
n.center = buildGameTree (nmatches-2,
(player == 'A')
? 'B' : 'A');
if (nmatches >= 3)
n.right = buildGameTree (nmatches-3,
(player == 'A')
? 'B' : 'A');
return n;
}
buildGameTree recursively builds a game tree that fully describes a Nim game, with a starting pile specified by nmatches prior to the recursion. This method uses if statements to ensure that Node objects are not created for those scenarios where the number of taken matches would exceed the number of matches currently in the pile (attempting to take three matches from a two-match pile, for example). For each terminal configuration Node object, buildGameTree assigns the winning player's name to that object's player field.
if
We can combine the Node class and the buildGameTree method to create Figure 1's game tree: Node root = buildGameTree (4, 'A');. That line of code specifies an initial pile of four matches, and that Player A goes first. (Note: These code fragments are excerpted from a GameTree application I built for this article. To access that application's source code, unzip the code.zip file.)
Node root = buildGameTree (4, 'A');
GameTree
Storing an entire game tree's nodes in memory is not practical for large game trees -- thousands or millions of nodes. However, with an initial pile of four (or even 11) matches, the resulting Nim game tree can be completely stored in memory.
The minimax algorithm determines a player's optimal move by assigning a number to each node that is an immediate child of the player's node. The optimal move for Player A is to follow the branch to the immediate child node with the maximum number. In a similar fashion, the optimal move for Player B is to follow the branch to the immediate child node with the minimum number. Although the optimal move doesn't guarantee a win for the player, it indicates the best possible outcome that the player can hope to achieve.
Node numbers are first determined at the terminal configuration node level. An evaluation function calculates these numbers. In Nim, this function is simple: return 1 if a terminal configuration node indicates Player A to be the winner, or -1 if Player B is shown to be the winner. Moving up one level, minimax then determines either the maximum or the minimum of all child numbers -- maximum if the parent node represents Player A's turn, or minimum if the parent node represents Player B's turn -- and assigns the result to the parent node. With each level that minimax moves up, it alternately determines the maximum or minimum prior to the assignment (which is how minimax gets its name). Figure 2 illustrates minimax being applied to Figure 1's game tree.
Figure 2. Game tree with a minimax value assigned to each node
In Figure 2, suppose the current node is the pink square node that contains 1, and is located two levels down and on the left side. That node indicates that it is Player A's turn to make a move. Should Player A take 1 match or 2? Here is what minimax determines: The leftmost terminal configuration node (at the lowest level) is assigned 1 because that node indicates a win for Player A -- Player B has just removed the last match and loses. Minimax assigns that value as the minimum to the parent Player B node. The terminal configuration node to the right of (and at the same level as) the Player B node (which contains 1) is assigned -1, because it indicates a win for Player B -- Player A has just removed the last two matches and loses. The maximum of 1 and -1 then assigns to the Player A parent node, which means Player A's optimal move is to take one match.
Earlier, you saw how Java was used to create a game tree. You will now see how Java is used to implement the minimax algorithm to search the game tree for Player A's optimal opening move. Examine the following code fragment, taken from the Minimax application that accompanies this article (see the code.zip file).
Minimax
// Build a game tree to keep track of all possible
// game configurations that could occur during
// games of Nim with an initial pile of four
// matches. The first move is made by player A.
Node root = buildGameTree (4, 'A');
// Use the minimax algorithm to determine if
// player A's optimal move is the child node to
// the left of the current root node, the child
// node directly below the current root node, or
// the child node to the right of the current root
// node.
int v1 = computeMinimax (root.left);
int v2 = computeMinimax (root.center);
int v3 = computeMinimax (root.right);
if (v1 > v2 && v1 > v3)
System.out.println ("Move to the left node.");
else
if (v2 > v1 && v2 > v3)
System.out.println ("Move to the center node.");
else
if (v3 > v1 && v3 > v2)
System.out.println ("Move to the right node.");
else
System.out.println ("?");
}
After building the game tree (shown in Figures 1 and 2), the code fragment invokes the computeMinimax method on the left, center, and right child nodes of the root node. Those numbers are then compared with each other to determine the maximum, and an appropriate message outputs to indicate which move to take. When you run this program, you'll discover that the optimal move is to the right node.
computeMinimax
Note: The observant reader will notice something strange about the code fragment: System.out.println ("?");. Although that method call is not chosen when the code fragment executes, it illustrates an important point that must be considered in the console-based and GUI-based versions of Nim: scenarios exist where all child nodes have the same minimax number. For example, consider a Nim game with an initial pile of six matches. Suppose you remove one match, leaving five. The three immediate child nodes of the node representing five matches all have the same minimax number. What is the optimal move in this and similar scenarios? Part 2 of this series answers that question.
System.out.println ("?");
What does computeMinimax look like? Check out the following code fragment:
static int computeMinimax (Node n)
{
int ans;
if (n.nmatches == 0)
return (n.player == 'A') ? 1 : -1;
else
if (n.player == 'A')
{
ans = Math.max (-1,
computeMinimax (n.left));
if (n.center != null)
{
ans = Math.max (ans,
computeMinimax (n.center));
if (n.right != null)
ans = Math.max (ans,
computeMinimax (n.right));
}
}
else
{
ans = Math.min (1,
computeMinimax (n.left));
if (n.center != null)
{
ans = Math.min (ans,
computeMinimax (n.center));
if (n.right != null)
ans = Math.min (ans,
computeMinimax (n.right));
}
}
return ans;
}
The computeMinimax method is recursive in nature. It begins with code that determines if its Node argument represents a terminal configuration node. If that is the case (n.matches contains 0), the evaluation function, which consists of a simple statement that returns 1 if the player field contains A or -1 if that field contains B, executes. Otherwise, the method "knows" it is dealing with some parent node.
n.matches
A
B
If the parent node's player field contains A, the method recursively obtains the maximum of the parent node's child node numbers. Care is taken to ensure that only existing child nodes are examined, to avoid a NullPointerException object being thrown. That maximum is then returned. Similarly, if the player field contains B, the method recursively obtains the minimum of the parent
node's child node numbers and returns the result.
NullPointerException
Computer games are entertaining and can reduce stress. If you have ever wanted to create your own version of a computer game, the simplicity of Nim makes it an excellent choice. In this article, after learning how to play Nim, you discovered game trees and the minimax algorithm for creating an intelligent computer player.
As usual, there is some homework for you to accomplish:
The number of nodes in Nim's game tree grows quite rapidly as the initial number of matches increases slightly. For example, one match yields two nodes, two matches yield four nodes, three matches yield eight nodes, and four matches yield 15 nodes. For 21 matches, how many nodes are created?
If you cannot store an entire game tree in memory because of its size, how could you adapt minimax to work with such a game tree?
Next month's Java Tech creates console-based and GUI-based Nim computer games. Each game applies this article's knowledge to its intelligent computer player.
The previous Java Tech article presented you with some challenging homework on variable arguments. Let's revisit that homework and investigate solutions.
Problem 1
Is void foo (String ... args, int x) { } legal Java code? Why or why not?
void foo (String ... args, int x) { }
Solution
void foo (String ... args, int x) { } is not legal Java code. It is not legal because args must be the rightmost parameter. Why? Consider a slightly different method header: void foo (int ... args, int x). Furthermore, consider the method call foo (10, 20, 30). Should 30 belong to args or to x? Obviously, we must assign 30 to x because each parameter must have a matching argument (or arguments, as in the case of a variable arguments parameter). However, the comma-delimited list implies that 30 belongs to args. Because Java cannot tolerate ambiguities, it enforces the rule that the variable arguments parameter must be the rightmost parameter.
args
void foo (int ... args, int x)
foo (10, 20, 30)
30
x
Problem 2
Create a PrintFDemo application that demonstrates many of the formatting options made available by Formatter.
PrintFDemo
Formatter
Solution
Consult the PrintDemo.java source code in this article's nim1.zip file.
Jeff Friesen is a freelance software developer and educator specializing in Java technology. Check out his site at javajeff.mb.ca.
View all java.net Articles. | http://today.java.net/pub/a/today/2004/05/18/nim1.html | crawl-002 | refinedweb | 2,728 | 64.91 |
TL;DR
Write fast, headless, tests for Backbone using Node.js. See this project as an example.
A Brief History
Artsy is mostly a thick client Backbone app that sits on Rails and largely depends on Capybara (Selenium backed bot that clicks around Firefox) for testing it’s javascript. This leads to some seriously brittle and slow integration tests. Despite being able to wrangle Capybara to do most of our client-side testing, we knew there must be a better way.
When building a CMS app for our gallery partners to manage their Artsy inventory, we built a new Backbone app on top of node.js. The result was a headless test suite that runs around 60 times faster.
Let’s take a look at how it’s done.
Setting Up The Environment
The trick to testing client-side code in node.js is creating an environment that mimics the browser. Jsdom does just that by bringing a pure javascript implementation of the DOM to node.js.
At this point we’ve globally exposed the
window object of our jsdom browser. However the DOM isn’t the only global dependency in most of our client-side code. We’ll also need to expose our common libraries like Backbone, Underscore, and jQuery.
We can simply require Backbone, Underscore, and jQuery like any node module because they follow CommonJS convention. However not all libraries are CommonJS compatible, and in this case you might have to expose their attachment to
window.
Finally you probably have a namespace like
App which your components attach to.
Try to keep global dependencies to a minimum. This reduces setup/teardown, increases modularity, and makes it easier to test your code.
For example, instead of attaching a view to
App it might be better to pass that view in to the options of another so you can call
this.options.header.doSomething().
Unit Testing Models
Because all good javascript guides are based off Todo apps, let’s pretend we’re testing a Todo model.
Let’s test that
#complete makes the proper API PUT and
completed is updated to true. After we setup our jsdom environment we need to stub
$.ajax using sinon as we won’t be sending XHRs in node.
Now we can simply assert that
$.ajax was called with the right params and completed changed.
Unit Testing Views
Models are easy to unit test because they’re mostly self-contained javascript. However a Backbone view might expect some server-side rendered HTML, use client-side templates, communicate to other views, and so on. This makes it harder to test but manageable given our set up.
Let’s pretend we have a view that renders our todo list inside a server-side rendered element, and uses a client-side template to fill in the actual list items.
Our DOM might look something like this:
and our view might look something like this:
We can render the server-side
#todos element by compiling the express view into html and injecting it straight in jsdom with our globally exposed jQuery.
Next we need to expose our client-side templates. In this case I’m assuming client-side templates are pre-compiled into functions namespaced under a global JST object like in the Rail’s asset pipeline (if you’re looking for a node.js tool nap is what Artsy uses).
We need to mimic what the JST functions are expecting so that when calling
JST['foo/bar']({ foo: 'some-data' }) we get back a string of html.
With our server-side HTML injected and our client-side templates ready to use, all that’s needed is to require any other dependent Backbone components. This boilerplate can get pretty repetitive and would be good to wrap up into a helper.
With a little bit more work, testing views in node can be almost as easy as testing models.
Integration Tests
Although I encourage writing way more unit test coverage as they’re faster and less brittle, it is necessary to have integration tests to cover longer scenarios. At Artsy we use some tricks to make integration testing less painful.
Stubbing the API Layer
In Artsy’s case we’re consuming a JSON API service that already has ample test coverage, so it makes sense to cut off integration at this point and stub our API responses.
To do this we can conditionally check which environment we’re running in and swap out the API to use a real API or an express app serving a stubbed API.
If our API was hosted on the same server as our client app, or we’re proxying API calls because of lack of CORS support, this could be as easy as swapping out middleware.
This speeds up integration tests and simplifies the stack by not populating a database or booting an API server.
Headless Integration Tests with Zombie.js
Selenium has to actually boot up Firefox and poll the UI to wait for things to appear. This disconnect means extra seconds of “wait_util we’re sure” time. Zombie.js is backed by our friend jsdom and alleviates these issues by giving us a fast headless browser that we can programmatically access.
Of course the caveat to headless testing is that you can’t visually see how a test is actually failing. Using
{ debug: true } in your options will spit every Zombie action to stdout. In most cases this is enough, but sometimes you need to go a step further and actually visualize what the test is doing.
A trick we use is to write tests using the browser’s
jQuery. This is more familiar than Zombie’s DSL and lets you copy and paste test code directly in your browser’s console to see if it’s actually doing what you want.
.e.g
Conclusion
Using these techniques has greatly increased productivity and developer happiness for testing client-side code. For an example implementation of this see.
Looking forward, testing client-side code can be made even better by using a package manager that adds require functionality like browserify, component, or require.js. But I’ve gone far enough for now, maybe in another blog post (leave a comment if you’re interested). | http://artsy.github.io/blog/2013/06/14/writing-headless-backbone-tests-with-node-dot-js/ | CC-MAIN-2014-15 | refinedweb | 1,041 | 62.48 |
Log message:
Update to 3.5.0
Upstream changes:
gtools 3.5.0 - 2015-04-28
-------------------------
New Functions:
- New roman2int() functon to convert roman numerals to integers
without the range restriction of utils::as.roman().
- New asc() and chr() functions to convert between ASCII codes and
characters. (Based on the 'Data Debrief' blog entry for 2011-03-09
at … -in-r.html).
- New unByteCode() and unByteCodeAssign() functions to convert a
byte-code functon to an interpeted code function.
- New assignEdgewise() function for making assignments into locked
environments. (Used by unByteCodeAssign().)
Enhacements:
- mixedsort() and mixedorder() now have arguments 'decreasing',
'na.last', and 'blank.last' arguments to control sort ordering.
- mixedsort() and mixedirdeR() now support Roman numerals via the
arguments 'numeric.type', and 'roman.case'. (Request by David
Winsemius, suggested code changes by Henrik Bengtsson.)
- speed up mixedorder() (and hence mixedsort()) by moving
suppressWarnings() outside of lapply loops. (Suggestion by Henrik
Bengtsson.)
- The 'q' argument to quantcut() now accept an integer
indicating the number of equally spaced quantile groups to
create. (Suggestion and patch submitted by Ryan C. Thompson.)
Bug fixes:
- Removed stray browser() call in smartbind().
- ddirichlet(x, alpha) was incorrectly returning NA when for any i,
x[i]=0 and alpha[i]=1. (Bug report by John Nolan.)
Other changes:
- Correct typographical errors in package description.
gtools 3.4.2 - 2015-04-06
-------------------------
New features:
- New function loadedPackages() to display name, version, and path of
loaded packages (package namespaces).
- New function: na.replace() to replace missing values within a
vector with a specified value.`
Bug fixes:
- Modify keywords() to work properly in R 3.4.X and later.
gtools 3.4.1 - 2014-05-27
-------------------------
Bug fixes:
- smartbind() now converts all non-atomic type columns (except factor)
to type character instead of generating an opaque error message.
Other changes:
- the argument to ASCIIfy() is now named 'x' instead of 'string'.
- minor formatting changes to ASCIIfy() man page.
gtools 3.4.0 - 2014-04-14
-------------------------
New features:
- New ASCIIfy() function to converts character vectors to ASCII
representation by escaping them as \x00 or \u0000 codes.
Contributed by Arni Magnusson.
gtools 3.3.1 - 2014-03-01
-------------------------
Bug fixes:
- 'mixedorder' (and hence 'mixedsort') not properly handling
single-character strings between numbers, so that '1a2' was being
handled as a single string rather than being properly handled as
c('1', 'a', '2').
gtools 3.3.0 - 2014-02-11
-------------------------
New features:
- Add the getDependencies() function to return a list of dependencies
for the specified package(s). Includes arguments to control whether
these dependencies should be constructed using information from
locally installed packages ('installed', default is TRUE), avilable
CRAN packages ('available', default is TRUE) and whether to include
base ('base', default=FALSE) and recommended ('recommended', default
is FALSE) packages.
Bug fixes:
- binsearch() was returning the wrong endpoint & value when the found
value was at the upper endpoint.
gtools 3.2.1 - 2014-01-13
-------------------------
Bug fixes:
- Resolve circular dependency with gdata
gtools 3.2.0 - 2014-01-11
-------------------------
New features:
- The keywords() function now accepts a function or function name as
an argument and will return the list of keywords associated with the
named function.
- New function stars.pval() which will generate p-value significance
symbols ('***', '**', etc.)
Bug fixes:
- R/mixedsort.R: mixedorder() was failing to correctly handle numbers
including decimals due to a faulty regular expression.
Other changes:
- capture() and sprint() are now defunct.
gtools 3.1.1 - 2013-11-06
-------------------------
Bug fixes:
- Fix problem with mixedorder/mixedsort when there is zero or one
elements in the argument vector.
gtools 3.1.0 - 2013-09-22
-------------------------
Major changes:
- The function 'addLast()' (deprecated since gtools 3.0.0) is no
longer available, and has been marked defunct.
Bug fixes:
- Modified 'mixedorder()' to use Use 'suppressWarnings() instead of
'options(warn=-1)'. This will avoid egregious warning messages when
called from within a nested environment, such as when run from
within 'knitr'
gtools 3.0.0 - 2013-07-06
-------------------------
Major changes:
- The function 'addLast()' has been deprecated because it directly
manipulates the global environment, which is expressly prohibited by
the CRAN policies.
- A new function, 'lastAdd()' has been created to replace 'addLast()'.
The name has been changed because the two functions require
different syntax. 'addLast()' was used like this:
byeWorld <- function() cat("\nGoodbye World!\n")
addLast(byeWorld)
The new 'lastAdd()' function is used like this:
byeWorld <- function() cat("\nGoodbye World!\n")
.Last <- lastAdd(byeWorld)
Bug fixes:
- Update checkRVersion() to work with R version 3.0.0 and later.
Other changes:
- Remove cross-reference to (obsolete?) moc package
- The function 'assert()' (deprecated since gtools 2.5.0) is no longer
available and has been marked defunct.
gtools 2.7.1 - 2013-03-17
-------------------------
Bug fixes:
- smartbind() was not properly handling factor columns when the first
data frame did not include the relevant column.
gtools 2.7.0 - 2012-06-19
-------------------------
New features:
- smartbind() has a new 'sep' argument to allow specification of the
character(s) used to separate components of constructed column names
- smartbind() has a new 'verbose' argument to provide details on how
coluumns are being processed
Bug fixes:
- smartbind() has been enhanced to improve handling of factor and
ordered factor columns. gtools v2.6.2, add LICENSE and regularize package files.
Log message:
Update to the latest version of the module along with R update
Log message:
Update R-gtools to 2.5.0
gtools 2.5.0
------------
New features:
- Add checkRVersion() function to determin if a newer version of R is
available.
- Deprecated assert() in favor of base::stopifnot
Bug fixes:
- Fix bug in binsearch() identified by 2.6.0 R CMD CHECK
Other changes:
- Improve text explanation of how defmacro() and strmacro() differ from
function().
- Update definitions of odd() and even() to use modulus operator
instead of division.
gtools 2.4.0
------------
- Add binsearch() function, previously in the genetics() package.
gtools 2.3.1
------------
- Add ask() function to prompt the user and collect a single response.
gtools 2.3.0
------------
- Update email address for Greg
- Add new 'smartbind' function, which combines data frames
efficiently, even if they have different column names.
Log message:
Remove empty PLISTs from pkgsrc since revision 1.33 of plist/plist.mk
can handle packages having no PLIST files.
Log message:
There is some debugging information in gtools.so.
Log message:
Initial import of R-gtools 2.2.3
Various R programming tools | http://pkgsrc.se/math/R-gtools | CC-MAIN-2018-05 | refinedweb | 1,054 | 58.99 |
java binary file io example
java binary file io example java binary file io example
How to copy a file
How to copy a file
In this section, you will learn how to copy a file using Java IO library. For
this, we have declared a function called copyfile() which...;}
}
The above code makes a copy of the file
Java Copy file example
Copy one file into another
Copy one file into another
In this section, you will learn how to copy content of one file into another
file. We
Copy Files - Java Beginners
Copy Files I saw the post on copying multiple files () and I have something... into a .txt file, importing that, and then somehow having Java read the filenames
copy file - Java Beginners
CopyFile{
public void copy(File src, File dst) throws IOException...copy file i want to copy file from one folder to another
...(String[] args) throws Exception{
CopyFile file=new CopyFile();
file.copy(new
Copy multiple files
Copy multiple files
.... For copping the data of multiple file, you need all files in a specified directory where... copyfile()
copies the contents of all given files to a specific file. When all
IO in java
IO in java Your search mechanism will take as input a multi-word... the words specified appear closer to one another. For
example, if you search... the directory as before along with a file containing a set of
queries. Each line
IO File - Java Beginners
IO File Write a java program which will read an input file & will produce an output file which will extract errors & warnings.
It shall exclude... from the log file.
This is the task assigned to me..Please help me
File copy through intranet - Java Beginners
File copy through intranet Can i copy files from system A to System B connected through intranet??
Is this possible through java IO?
If yes, please let me know
java IO
java IO Write a Java program to accept a file name as command line argument.
Append the string "File Modified by Programme" to the end of the same file and print the contents of the
modified File io
java io Write a program to use a File object and print even numbers from two to ten. Then using RandomAccessFile write numbers from 1 to 5. Then using seek () print only the last 3 digits
Copy Directory or File in Java
Copy Directory in Java
...;
Introduction
Java has the features of the copying the directory and it's contents. This
example shows
java IO programing
java IO programing how Java source file is used as input the program will echo lines
copy file from folder to folder - Java Beginners
.. it varies
can you please provide sample example to copy the file
regards...copy file from folder to folder my requirement is I need to copy... wich contains the file to be copied.
I want to copy the file from
IO concept
IO concept Write a java program that moves the contents of the one file to another and deletes the old file.
Hi Friend,
Try...!");
}
}
For more information, visit the following link:
Java Move File
Thanks
Copy a file to other destination and show the modification time of destination file
;
This is detailed java code that copies a source file to
destination file, this code checks all the condition before copy to destination
file, for example- source... Copy a file to other destination and show the modification time
java io
java io by using java coding how to invoke a particular directory
Java IO
Java IO What an I/O filter
Copy one file into another
Copy one file into another
In this section, you will learn how to copy content of one file into another
file. We will perform this operation by using... you a clear idea :
Example :
import java.io.*;
public class CopyFile
Java - Copying one file to another
Java - Copying one file to another
This example illustrates how to copy contents from one...) of java.io
package.
In this example we are using File class of java.io
package... a string containing a path name or a File object.
3. You can also specify whether you want to append the output to an existing file.
public FileOutputStream
Java IO SequenceInputStream Example
Java IO SequenceInputStream Example
In this tutorial we will learn about... in the sequence of files in
which they are ordered i.e. reads the first file until reached at end the of
file and then reads another file until reached at the end-io - Java Beginners
java-io Hi Deepak;
down core java io using class in myn...://
Thanks
copy() example
Copying a file in PHP
In this example, you will learn 'how to copy a file in PHP programming language?'
For copying a file, we use copy command from source...;;
if(copy($source, $destination)) {
echo "File copied successfully."
File copy from one drive to another. - Java Beginners
File copy from one drive to another. I want to copy a .mp3 file from one drive(let d: drive)to another drive(let e: drive) in my Windows XP. How can I do
how to sort multiple key columns in CSV file - Java Beginners
how to sort multiple key columns in CSV file Hi
Any one can assist how to sort the multiple key columns in CSV file?
Any example will be appreciated.
Thanks
io - Java Beginners
.
Thanks
Amardeep
Java IO PrintWriter
Java IO PrintWriter
In this tutorial we will learn about the the PrintWriter class in Java.
java.io.PrintWriter class is used for format printing of objects...
the PrintWriter in the Java applications. In this example I have created
Simple IO Application - Java Beginners
Simple IO Application Hi,
please help me Write a simple Java application that prompts the user for their first name and then their last name. The application should then respond with 'Hello first & last name, what
Java IO PushbackReader
Java IO PushbackReader
In this section we will discuss about the PushbackReader class in Java.
PushbackReader is a class of java.io package that extends.... In this example I have created a simple Java class
named
Java array copy example
Java array copy example
In this section we will discuss about the arrayCopy() in Java.
arrayCopy() is a method of System class which copies the
given...)
Example
Here I am giving a simple example which will demonstrate you about how
Java - Copying one file to another
:\nisha>java CopyFile a.java Filterfile.txt
File copied...
Java - Copying one file to another
... how to copy contents from one
file to another file. This topic is related
Copy and pasting - Java Beginners
Copy and pasting hi all, I am copying some cells from excell... JPopupMenu popup; JTable table; public BasicAction cut, copy, paste, selectAll...); copy = new CopyAction("Copy", null); paste = new PasteAction("Paste",null)
Copy file in php, How to copy file in php, PHP copy file
Learn How to copy file in php. The PHP copy file example explained here.... It returns the true or false Value.
Copy file example code
<?php...;
In the following example we will show you how to use of copy() function in php
Multiple file Uploading - JSP-Servlet
Multiple file Uploading Hello everyone
I am using jsp and my IDE is eclipse and back end is ms sql server
i am trying to upload multiple... class for JSP:
An error occurred at line: 9 in the generated java file
cut,copy,paste
cut,copy,paste plz... give me the coding of cut,copy and paste in Java (Netbeans
Merge multiple jasper file to one word Doc using java
Merge multiple jasper file to one word Doc using java how to Merge multiple jasper file to one word Doc using java
Using a Random Access File in Java
:
C:\nisha>java ReadAccessFile
Enter File name : Filterfile.txt...C:\nisha>javac RandAccessFile.java
C:\nisha>java RandAccessFile
Enter File name : Filterfile.txt
Write
Java Multiple Insert Query
Java Multiple Insert Query
In this example we will discuss about how to execute multiple insert query in
Java.
This example explains you about how to execute batch insert in Java. This
example explains all the steps for executing
Java FTP file upload example
Java FTP file upload example Where I can find Java FTP file upload...; Hi,
We have many examples of Java FTP file upload. We are using Apache... Programming in Java tutorials with example code.
Thanks
Copy Mails to Xl sheet - JavaMail
Copy Mails to Xl sheet Can somebody give me the Java code to copy outlook mails into an Xl sheet
Java IO StringReader
Java IO StringReader
In this section we will discuss about the StringReader... in Java. In this example I have created a Java class
named...;
String str = "\n Java IO StringReader \n";
try
Uploading Multiple Files Using Jsp
a file.
In
this example we are going to tell you how we can upload multiple files... Uploading Multiple Files Using Jsp
... to understand how you can upload multiple files by using the Jsp.
We should avoid
How to read file in java
How to read file in java
Java provides IO package to perform reading... file line by line
in java.
FileInputStream- This class reads bytes from... file in Java:
Another way of reading a file:
The another program
Read Text from Standard IO
operations on files.
Java also supports three Standard Streams...);
Working with Reader classes:
Java
provides the standard I/O facilities for reading text from either the file or
the
keyboard on the command
multiple inheritance.
multiple inheritance. hello,
can java support multiple inheritance???
hi,
java does not support multiple inheritance
Java Method Return Multiple Values
Java Method Return Multiple Values
In this section we will learn about how a method can return multiple values
in Java.
This example explains you how... the steps required in to return multiple values in
Java. In this example you will see
multiple browsers in java script - JSP-Servlet
multiple browsers in java script How to make my jsp browser specific? Hi friend,
For solving the problem visit to :
Thanks
related to multiple thread....!!!!
related to multiple thread....!!!! Write a Java program, which..., the information of whole linklist should be stored in a file.(Everytime the linklist wont write its Content in a file, it will be only performed when application exits
Copy a Html chart into PPT - Java Beginners
Copy a Html chart into PPT Hi Experts,
i am facing with a problem without solution.
I have a Html site and would like to write a code so that by clicking on a button the graph will be copied in an active ppt.
Could you
Multiple inheritance using interface - Java Beginners
Multiple inheritance using interface Hi,
I understand.... But the use of the interface is when we use multiple inheritance with more than one.... Please let me show that sample example to understand the use of interface
java - Java Beginners
java how to write a programme in java to copy one line file to another file.name of file are entered through a keyboard Hi Friend,
Try...();
System.out.println("Destination File");
String f2=input.next();
copyfile(f1,f2 | http://www.roseindia.net/tutorialhelp/comment/15740 | CC-MAIN-2014-52 | refinedweb | 1,861 | 63.09 |
Seam components in different jarsBreako Beats Nov 9, 2006 10:15 AM
Is it ok to have seam components in different jars?
I presume to do this all Ineed to do is ensure that each jar has a seam.properties file, this would mean my application would have more than one seam.properties file overall is this ok?
This content has been marked as final. Show 3 replies
1. Re: Seam components in different jarsGregory Pierce Nov 9, 2006 12:09 PM (in response to Breako Beats)
I have a similar situation, but for some reason my application isn't working and I'm chatting with Gavin about it.
I can tell you this much though, if you don't have multiple seam.properties it definitely WILL NOT work :)
2. Re: Seam components in different jarsSerg Prasolov Nov 14, 2006 11:21 AM (in response to Breako Beats)
I have a similar problem, a component is in the second jar.
Seam from cvs, JBoss 4.0.5.GA.
Component
@Scope(ScopeType.STATELESS) @Name("localeStuff") @Intercept(InterceptionType.NEVER) public class LocaleStuff { public void select(ValueChangeEvent event) {...} }
lives in add.jar. It is set up similar to jboss-seam.jar in application.xml:
... <module> <java>jboss-seam.jar</java> </module> <module> <java>add.jar</java> </module> ...
The add.jar is put into ear file as jboss-seam.jar is.
The component is used in xhtml file:
... <h:selectOneMenu <f:selectItems </h:selectOneMenu> ...
But when I access a page, I had:
/abc.xhtml @40,72 valueChangeListener="#{localeStuff.select}": Target Unreachable, identifier 'localeStuff' resolved to null
Can components be put into different jars and how to do it correctly?
3. Re: Seam components in different jarsSerg Prasolov Nov 14, 2006 11:26 AM (in response to Breako Beats)
A-ha, I put an empty seam.properties file into the add.jar and it works now. Good, but very weird... Should be placed in FAQ? | https://developer.jboss.org/thread/133182 | CC-MAIN-2018-13 | refinedweb | 320 | 61.43 |
Asked by:
IDXGISwapChain1::Present1 and screen color
I'm new to Direct2D and XAML app development and can't figure this one out, so any help will be highly appreciated. I created a new "Direct2D App (XAML)" project in Visual Studio Express 2012. This project has SimpleTextRenderer class (derived from DirectXBase) that displays text on screen using Direct2D. The XAML page calls the following functions:
...
m_renderer->Render();
m_renderer->Present();
...
The Present() function has the following line of code in it:
HRESULT hr = m_swapChain->Present1(1, 0, ¶meters);
where m_swapChain is an instance of IDXGISwapChain1.
If I omit the call to m_renderer->Render() function and just invoke m_renderer->Present() in some timer callback, the screen color changes. Now I know that the project also demonstrates how the background color can be changed when "Next" and "Previous" buttons are pressed in the bottom app bar, but I commented that code out and the screen color keeps changing (in the callback for timer that I set up) by itself, even when I don't press any buttons. Is this behavior expected? What is the behavior of Present1() function if it's called again and again and there's nothing to draw? Does it show empty frames in different colors or is that a bug somewhere?
To duplicate this problem, please create this project in VS 2012 and add the following code in DirectXPage::DirectXPage():);
The problem obviously goes away if I un-comment the call to Render() 'cause that functions clears the screen and draws some text again. I just want to know why the screen color is changing in the scenario I described above. Please let me know if more information is needed.Tuesday, January 01, 2013 3:39 AM
Question
All replies.Wednesday, January 02, 2013 6:18 AM
Hi Jesse,
Thanks for the reply. The problem is fairly easy to reproduce with the project that "VS Express 2012 for Windows" creates. Here are the steps:
1. Launch Visual Studio Express 2012 for Windows 8.
2. Select File -> New Project
3. Select "Direct2D App (XAML)" under Visual C++. This will create a whole bunch of files including SimpleTextRenderer.cpp, and DirectXPage.xaml.cpp.
4. In DirectXPage.xaml.cpp, add this line at the top: "using namespace Windows::System::Threading;"
5. In DirectXPage::DirectXPage() function, copy the following code after the call to m_renderer->Initialize:);
6. Now run the program. You'll see that the screen color keeps changing after every call to m_renderer->Present().
I commented out all references to BackgroundColors in SimpleTextRenderer.cpp to make sure that that's not causing it (even though that should only come into action when next and previous buttons are pressed), but the color still changes.
Please let me know if you are able to reproduce the problem or not. A quick reply will be appreciated.
Thanks.
Tuesday, January 08, 2013 6:35 AM | https://social.msdn.microsoft.com/Forums/en-US/97ae8062-bddf-4573-bdc4-4ccc826f7b88/idxgiswapchain1present1-and-screen-color?forum=winappswithnativecode | CC-MAIN-2018-09 | refinedweb | 480 | 65.22 |
LinuxQuestions.org
(
/questions/
)
-
Programming
(
)
- -
Brand New to Linux, intermediate Programmer, want to program for linux destop apps
(
)
albertrosa
12-07-2003 07:49 PM
Brand New to Linux, intermediate Programmer, want to program for linux destop apps
Hello everyone Just last week (12/4/03) i've purchased SuSE 9.0 Pro. And i wish to program for linux. but i can't work my way into programming anything where as how can i get diddally to work (compilers, executable programs) Is there any media out there that can tell me what i would have to do to program in C++, Java 2 and Perl.
I wish to make Linux onto a more Desktop OS so i wish to help but don't have any clue to make it work. i would love any information that i can recieve from anyone.
pablob
12-08-2003 06:47 AM
The easiest for C++ would be to use Qt tools.
Check if you've got installed QT develop packages.
(K Menu - Applications - Development - QT Designer)
QT Designer is kind of a MS V. Studio.
If it is not installed in your system, sure the is an rpm file in your distro's CD's.
(For MDK9.1: libqt3-devel-3.1.1-13.1mdk )
You can also choose KDevelop as GUI
On the other way, you could choose to develop for Gnome and/or GTK2 or even C# & "Mono" architecture, but I think that's at least harder for beginnings and could be less productive for a newbie.
teval
12-08-2003 06:59 AM
Try to google for
linux gcc
gcc is the defacto c/c++ compiler.
Yeah.. qt is cute.. but nothing more then just a widget system. I like GTK more.. even though I never use Gnome.
Try searching for linux java and so on, you'll find info on it easily.
memory_leak
12-08-2003 07:00 AM
What makes you intermediate programmer?
How do u measure that?
*just curious*
btw:
in your console:
1) type: emacs hello.c &
2) hit enter
3) copy code below into that window that opened:
#include <stdio.h>
main()
{
printf("Hello World!\n");
}
3) in emacs window; press ctrl button; and then while holding ctrl press 'x' and then (still holding ctrl) 's' - emacs should now save your code into file called hello.c
4) in your console window write:
gcc -o hello hello.c
5) hit enter
6) still in console write:
./hello
7) hit enter
at this point you should see some output like :
Hello World!
on your console.
After you have written this essential diddaly to work you will probably list out how to write next generation desktop diddalys on your own.
good luck!
I wish that helped.
albertrosa
12-08-2003 07:49 AM
Thank you everyone for your input i am installing Qt to see how it functions with my personal needs,i've ran a search for Linux Java - found some interesting information. I also ran your Hello world and it work just as expected thank you everyone for your input
All times are GMT -5. The time now is
09:21 AM
. | http://www.linuxquestions.org/questions/programming-9/brand-new-to-linux-intermediate-programmer-want-to-program-for-linux-destop-apps-123687-print/ | CC-MAIN-2016-36 | refinedweb | 527 | 72.66 |
User talk:Makopoppo
From OpenSimulator
Latest revision as of 12:28, 28 March 2012
[edit] Hello from Friti
Hi Makopoppo,
I just wanted to say thank you for doing so much to help improve the wiki. Now i don't feel so alone anymore :-)
Let's keep in touch about our ideas and plans for the wiki, so that we can help eachother do the things that need to be done :-)
P.S. Happy new year!
--Fritigern 19:25, 1 January 2011 (UTC)
[edit] Trash bin
It's a nice idea, and does hide the title of the old pages. But the problem is that those pages still remain on the the wiki. This problem also exists when using the template, but the difference is that with the template, all the pages will be gathered under Category:To Delete, where they will sit until Justin can get around to killing them all off.
Redirecting to trash may therefore only lead to forever hiding them, and never actually getting them deleted.
--Fritigern 09:08, 3 June 2011 (UTC)
- Thank you for commenting. That's why I added a line to WikiTodo to peep in Special:WhatLinksHere/Trash_Bin. And, actually only the current active sysop is Justincc, and he is busy on codes, coming features and a lot of bugs added to Mantis every day. So we anyway cannot rely on immediate maintenance of Wiki and therefore we as users basically have to act against the problem by ourselves - do our best to hide those page as soon as possible.
- Or, if you are interested in becoming sysop to solve the problem quickly, you might want to let Justincc know.
- -- Makopoppo
- Thanks to Justincc, now we both have ops, so we can simply delete spam pages and images immediately. I've deleted every spams as much as I can find, and I'll check User Contributions of New Accounts to watch the activities of newly created accounts, I think which is the most efficient way of finding spams - as far as I see, all the spammers post one page and one image per account. Note that images will not be on the ToDelete list even if you add {{delete}} tag, so you anyway find them by Special:NewImages. Thanks -- Makopoppo 02:20, 4 June 2011 (UTC)
[edit] Entry on development team page?
Hey Makopoppo. Do you think it would be a good idea to have an additional section for wiki sysops on the Development Team page? I'd really like to give you guys some recognition for the work that you're doing Justincc 14:24, 4 June 2011 (UTC)
[edit] Language links in template
Hi Makopopo,
I was doing some maintenance on Заглавная_страница (Russian main page), and i can't figure out how to get the language bar to work properly.
I also don't know Russian, and i don't think you would know any either :-)
Anyway, could you have a look at that page? I am not sure if "language bar" is the correct term, but it's the bar just below the one with the buttons from {{template:quicklinks}}
--Fritigern 09:25, 5 June 2011 (UTC)
- I fixed and saved. {{MainPageQuicklinks}} and {{Quicklinks}} can have one argument which is the name of original(english) page. If argument not provided, the page itself will be considered as original(english) and language link won't appear. By the way, {{MainPageQuicklinks}} is used only for Main Page and its localizations, which has larger icons than {{Quicklinks}}. I almost forget to mention about the difference between {{Template:Quicklinks}} and {{Quicklinks}} - both are just the same and generally the latter is often used.-- Makopoppo 10:01, 5 June 2011 (UTC)
- Wow, that's pretty confusing. I should read this again after i have had some sleep :-) Thank you for fixing it though. It's been bugging me for some time now.
- --Fritigern 10:06, 5 June 2011 (UTC)
- Okay, i've had some sleep, and i am starting to understand. Can we do away with {{Template:Quicklinks}} and just keep {{Quicklinks}}? Maybe we can create a bot for certain search/replace functions. I'm sure it will come in handy.
- --Fritigern 22:37, 5 June 2011 (UTC)
- I fix it when I notice and there is another thing to change. I personally think it is not so important thing to fix around manually only for that, the page appearance won't changed. And if we do manually, Recent Changes page will become too complicated so it will be hard for the users to find the changes in the articles. If we have bot, it will be handy and bots won't dirt Recent Changes if it is properly set. Can you write a bot script? I want to do that but I have some articles to finish up soon. Thanks. -- Makopoppo 23:13, 5 June 2011 (UTC)
I wish i knew how to write a bot, but i'm afraid i don't know how to do that. However, we may not have to wrote a bot ourselves. There may be one (or more) already available somewhere. We should look into this :-) --Fritigern 00:22, 6 June 2011 (UTC)
- mokay... I created my own bot with DotNetWikiBot Framework and it works fine now. I'll run it fully after my bot account is added in bot group so that the wiki history won't dirt anymore(Justincc seems to be away today so I guess it will take a few days). For now, I'll make it remove "Template:" prefix and replace external links to internal one. -- Makopoppo 13:31, 6 June 2011 (UTC)
[edit] Should the wiki be upgraded?
First off, it's awesome that you've got a bot working. I've looked into it, and it just confused me. Ah well... ^_^
Now, i have been looking at Special:Version and i was pretty shocked to see that the wiki (the MediaWiki software, that is) is still at v1.13, which came out in 2008. More recent versions have better protection against spam, auto-completion in search, and a lot more improvements that are either badly needed here, or desired.
What do you think, should we nag Justin and ask him to upgrade the wiki?
--Fritigern 16:11, 8 June 2011 (UTC)
- At least not now! He's still recovering... It's rather joke but I personally don't think that it will improve our experience of writings and settings quite much. As far as I've seen from its release notes, the progress stays within server-side settings and the system against h@ckings. Actually, v1,13 has anti-spam feature - but we can't change server-side settings to enable it, since it is php variables in MediaWiki deploy, not changeable from wiki interface. -- Makopoppo 10:21, 9 June 2011 (UTC)
- I'd love to upgrade the wiki but unfortunately it's a question of getting the time. It's not straightforward because there are various links and things mixed in (e.g. mantis). But it does need to be done. If there's a really compelling new feature or security fix then please do bug me about this Justincc 21:22, 27 June 2011 (UTC)
[edit] An Idea Which Has Been On My Mind For Some Time
As the header says, this idea has been on my mind for some time now, but only now do i actually have a little more clear picture in my head about this.
Let me try to say this as briefly as i can, if it lacks in tact, then it's not meant like that, i just want to get my idea across:
My idea is to virtually split the wiki in 2 or more parts. A part for developers and/or advanced users, and a part for less tech savvy end users. I will call these parts Developers and Users, just to give them a name.
The Developers part should contain technical documentation, development status, etcetera. Basically everything that regular users would not be able to understand, or are simply not interested in.
The Users part would contain basic info, documentation, and procedures, like how to set up a server in wordings that they can understand, or what to do if they can't connect their server to the grid that they signed up for. Or even how clone the git and compile OpenSim on their own (which is a very confusing article to regular people, btw).
The Users part can again be split up in sections for beginners, intermediate, and advanced, should this be needed. The Developers part could be split up too, in however way would be useful.
I do realize that splitting, or sorting, the wiki this way would take a lot of time. Although most of it would be moving articles and categories into a new, into an additional, or into a different category. Several articles will have to be split into a user part, and an advanced or developer part.
I definitely think that this would benefit the usability for all users of the wiki, from beginners, to developers, and even the sysops. Because everyone would be able to easily find information at their own level of expertise.
I would really like to hear your thoughts about this.
P.S. I also think it would be a good idea to have several portals on the wiki, and either link to them from the main page, or add them to the main page.
P.P.S. I am discussing this idea with you, because we really should stop having our own little or large projects, and collaborate as much as possible. We should know what the other is doing and try to help eachother as much as we can. To use a duth expression: we need to get our noses to face in the same direction. If we don't, then we will just keep getting in eachother's way. So communication is vital, and we will have to agree on things that will impact the wiki, wether the impact will be large or small.
--Fritigern 14:19, 2 August 2011 (UTC)
- Sorry for being quick reply, and I haven't yet fully read your comment, if my reply is far off the mark. I have written the memo in User:Makopoppo/ThoughtOfGuidesTOC, which has my thought about the possible document TOC. I'm not sure it is cover the full topic about OpenSimulator, but it would be some reference for considering categorizing the contents. I'm now working on mantis, there are still ton (no longer ton from a few days ago though) of issue piling for years, so for me wiki is rather low priority(except spam or some trifle issue). I'll read your comment tomorrow (or a few hours later in your timezone), and might make some comment, but I maybe can't actually move well on the wiki until the mantis issues will be cleared for some amount. -- Makopoppo 14:33, 2 August 2011 (UTC)
- I've just read the discussion on the mailing list and it looks like my idea gave you additional ideas, which is cool, although i don't think that creating new subdomains would be a good idea. It would make it feel like the wiki was really split into multiple different wikis. This would also cause problems with overlap I think my idea is a little simpler., which is to make use of namespaces and categories. Should an overlap occur (like if there's an article that can be placed under advanced users, but also under developers), we can simply add them to both categories. But placing them into two different subdomains would take more work.
- As sysops, we can just go ahead, and do all this. In the end, it will improve the readability. It will give the users of the wiki a starting point at their own level. A start could be to create new categories, and start moving other categories into them, and later re-categorise individual articles.
- This would be a pretty big step. But i am sure that it would work well for everyone.
- P.S. It look like the people on the mailinglist don't know that you are a wiki sysop, and i also think that Dahlia thinks you are proposing a new article....
- --Fritigern 20:38, 3 August 2011 (UTC)
- I'm writing this in the train on ipad. If my spell is broken, it woule be probablly because of that. Since you said "communication is vital, and we will have to agree on things that will impact the wiki", I thought communication with people is before going is vital too. You parhaps already know but, dahila and meranie is Beaurocrats on this wiki, higher than ours. And we simply undergo the job the users might want to do that for them, so if we make big changes, I think we'd better consulting it to them before going. And in the mailinglist we "can" say our opinion as an user, not as a sysop, it is great point. Indeed we might feel they are not so kind to understand our opinion easily, but they have "created" OpenSimulator for years, and many of the users on mailinglist have contributed their articles or support for newbies, they shouled be ther person to be respected. My sight is, wiki sysop jobs is, to say, like "clearing undergrowth", which as itself is not so "superior" job. I'll continue discussing it on the mailinglist, if you have some more opinion, you might want to post it there too. (Since despite the link to here, they likely not keep watching here) --Makopoppo 23:41, 3 August 2011 (UTC)
[edit] Something i have been playing with
I am not sure if you have seen it yet, but i have been working on a footer box for categorized pages, somewhat similar to what Wikipedia has.
My idea is to add these footer boxes to the end of pages of certain categories. Like we can have a footer box with interesting links to pages in the user category, the developer category, scripting, OSSL, Physics, etcetera. It would be like a standardized "see also" section.
To see what I mean, please have a look at User:Fritigern/BrainStorm#Footerbox_template, but keep in mind that i am not completely happy with it yet. Still, this is the basic idea, and it would be great if we can fix the layout of the footer box, maybe add some features, and then deploy it.
I would like to hear your thoughts about this.
--Fritigern 18:06, 20 September 2011 (UTC)
[edit] Suggestion Box Ideas
The recent spam attacks and other issues hitting the OpenSimulator.org site I suggested the following which Friti suggested I point out to you as well. Have a peek-a-boo at MediaWiki_talk:Titleblacklist
hope it helps --WhiteStar 13:28, 28 March 2012 (PDT) | http://opensimulator.org/index.php?title=User_talk:Makopoppo&diff=cur&oldid=22667 | CC-MAIN-2022-05 | refinedweb | 2,500 | 67.89 |
Hello,
I need to specialize the strategy of supression of elements in fonction of
the different previous element that have been explored.
I try to use a PropertySuppressionStrategy but we just have access to the
current element.
Here is an example of code :
Class class
public class Class1 {
private Class2 name1;
...
public class Class2 {
private Class3 name2;
private Class3 name3;
...
public class Class3 {
private String name4;
...
I am doing my filter by parametrisation and I describe all the fields I need
like that :
I want the field :
Class1.name1.name2.name4
I don't want the field :
Class1.name1.name3.name4
So, in order to excluse "Class1.name1.name3.name4", I need to knwow that the
name of the attribut of "Class3" in the class "Class2" is "name3" and not
"name2". Its seems to be impossible because in the
PropertySuppressionStrategy, we just have acces to the class containing the
property, class of the property, and name of the property.
Any idea ?
Regards.
Cédric | http://mail-archives.apache.org/mod_mbox/commons-user/200808.mbox/%3C002901c90110$dd343320$9801a8c0@DELLD820CAU%3E | CC-MAIN-2015-48 | refinedweb | 163 | 64.41 |
SSL_SESSION_up_ref,
SSL_SESSION_free—
#include <openssl/ssl.h>int
SSL_SESSION_up_ref(SSL_SESSION *session); void
SSL_SESSION_free(SSL_SESSION *session);
SSL_SESSION_up_ref() increments the reference count of the given session by 1.
SSL_SESSION_free() decrements the reference count of the given session by 1. If the reference count reaches 0, it frees the memory used by the session. If session is a
NULLpointer, no action occurs. is completely freed as the reference count incorrectly becomes(3);_SESSION_up_ref() returns 1 on success or 0 on error.
SSL_SESSION_free() first appeared in SSLeay 0.5.2 and has been available since OpenBSD 2.4.
SSL_SESSION_up_ref() first appeared in OpenSSL 1.1.0 and has been available since OpenBSD 6.3. | https://man.openbsd.org/SSL_SESSION_free.3 | CC-MAIN-2018-47 | refinedweb | 109 | 53.27 |
On Mon, Apr 13, 2009 at 05:00:05AM -0400, John A. Sullivan III wrote: > Thank you. I'll detail our script and the logic behind it in a separate > email in case it is helpful to others. > > In the meantime, we have a critical problem where the script which was > working perfectly in 5.2 is now broken in 5.3. Is there any way to > deconfuse the 5.3 multipathd or any other immediate solution? - John What christophe said is correct. In RHEL 5.3, multipath started copying all of the necessary callouts into it own private namespace. It scans through your config file, and pulls out all the binaries. However, there are two problems that are affecting you. First, it only pulls the command, "/bin/bash" in you case, not the arguments, which for you include a script to run. Second, it's private namespace only consists of /sbin, /bin, /tmp, a couple of virtual filesystems, like /proc and /sys (well, actually there are a couple of others, like /etc, that multipath needs to start up, but you shouldn't rely on them being there all the time, since you can lose access to them if the device they're on goes down) There are two ways to deal with this. First is to rewrite the prioritizer in C. I realize that this is a pain, but it will be necessary to run on RHEL6 and new fedora machines, which use upstream's prio functions instead of callout binaries. The second, quicker way is to move your callout to /sbin and add a dummy device section to make sure it gets picked up. devices { ... device { vendor "dummy" product "dummy" prio_callout "/sbin/mpath_prio_ssi" } } This will cause multipathd to copy your script into the private namespace, and everything should work, with one exception. bash is not a statically linked executable. It links to libraries, and multipathd doesn't make its own copies of them. Under normal operation this will work (/lib is also in multipathd's private namespace). However, if you lose access to /lib, bash won't work, and multipathd won't be able to restore access to your devices. If you aren't planning on multipathing / or /lib you might choose to ignore this (The exact same problem exists in 5.2). I don't believe that there is a statically linked shell in RHEL 5. This is another reason to convert your callout to a C program. Or you can recompile bash with static linking. -Ben > On Sun, 2009-04-12 at 09:13 +0200, christophe varoqui free fr wrote: > > John, > > > > Redhat-shiped multipathd populates upon start-up a private mem-backed filesystem with binaries it needs. > > Prio callouts in the form "$SHELL /path/to/myscript" seem to confuse the logic. > > If you prio callout is of general interest, may be we can port it upstream (as a shared object). > > If you are interested, please describe and post the source. > > > > Regards, > > cvaroqui > > > > ----- Mail Original ----- > > De: "John A. Sullivan III" <jsullivan opensourcedevel com> > > À: "device-mapper development" <dm-devel redhat com> > > Envoyé: Dimanche 12 Avril 2009 06h07:55 GMT +01:00 Amsterdam / Berlin / Berne / Rome / Stockholm / Vienne > > Objet: Re: [dm-devel] multipath prio_callout broke from 5.2 to 5.3 > > > > On Sat, 2009-04-11 at 23:54 -0400, John A. Sullivan III wrote: > > > Hello, all. We are facing a serious problem with dm-multipath after our > > > upgrade. We use a bash script to set priorities for failover. We > > > understand multipathd cannot use a bash script directly so it has been > > > carefully crafted to use only internal commands and is loaded as: > > > > > > prio_callout "/bin/bash /usr/local/sbin/mpath_prio_ssi %n" > > > > > > This has been working perfectly fine. We upgraded our test lab to > > > CentOS 5.3, device-mapper-multipath.x86_64 0.4.7-23.el5_3.2, kernel > > > 2.6.29.1 (the 2.6.18 default causes a kernel panic with iSCSI). > > > Suddenly, it is breaking. /var/log/messages is filled with: > > > > > > Apr 11 23:17:15 kvm01 multipathd: cannot open /sbin/dasd_id : No such file or directory > > > Apr 11 23:17:15 kvm01 multipathd: cannot open /sbin/gnbd_import : No such file or directory > > > Apr 11 23:17:15 kvm01 multipathd: [copy.c] cannot open /sbin/dasd_id > > > Apr 11 23:17:15 kvm01 multipathd: cannot copy /sbin/dasd_id in ramfs : No such file or directory > > > Apr 11 23:17:15 kvm01 multipathd: [copy.c] cannot open /sbin/gnbd_import > > > Apr 11 23:17:15 kvm01 multipathd: cannot copy /sbin/gnbd_import in ramfs : No such file or directory > > > Apr 11 23:17:15 kvm01 multipathd: /bin/bash exitted with 127 > > > Apr 11 23:17:15 kvm01 multipathd: error calling out /bin/bash /usr/local/sbin/mpath_prio_ssi sdc > > > Apr 11 23:17:15 kvm01 multipathd: /bin/bash exitted with 127 > > > Apr 11 23:17:15 kvm01 multipathd: error calling out /bin/bash /usr/local/sbin/mpath_prio_ssi sdd > > > Apr 11 23:17:15 kvm01 multipathd: /bin/bash exitted with 127 > > > Apr 11 23:17:15 kvm01 multipathd: error calling out /bin/bash /usr/local/sbin/mpath_prio_ssi sde > > > Apr 11 23:17:15 kvm01 multipathd: /bin/bash exitted with 127 > > > > > > The first several messages are expected but not the latter ones. If we > > > run the call from the command line, e.g., > > > "/bin/bash /usr/local/sbin/mpath_prio_ssi sdc" it works perfectly fine. > > > > > > What has changed and how do we fix it? I'll include a sample script > > > below. The script is dynamically created just before launching > > > multipathd: > > > > > > #!/bin/bash > > > # if not passed any device name, return a priority of 0 > > > if [ -z "${1}" ];then > > > echo 0 > > > exit > > > fi > > > > > > > > > > > > > > > > FOUND=0 > > > IFSORIG=${IFS} > > > IFS=$'\n' > > > for LINE in ${DEVS} > > > do > > > ENTRY=${LINE%/${1}} > > > if [ ${#ENTRY} -ne ${#LINE} ];then # We found the line > > > FOUND=1 > > > break > > > fi > > > done > > > if [ "$FOUND" = "0" ];then # This is not an iSCSI device > > > echo 0 > > > exit > > > fi > > > > > # > > > > PRIORITY=0 > > > for LINE in ${LIST} > > > do > > > DISK=${LINE%->*} > > > if [ "${DEV}" = "${DISK}" ];then > > > > > break > > > fi > > > done > > > echo ${PRIORITY} > > > > > > I did notice the semantics of /dev/disk/by-path changed and we adapted > > > to that. We were planning to move this to production on Thursday so > > > this has thrown a huge spanner in the works. Any help would be greatly > > > appreciated. Thanks - John > > > > I've just notice that my console is filled with: > > > > /bin/bash: /usr/local/sbin/mpath_prio_ssi: No such file or directory > > > > but it is indeed there and owned by root and executable. I've quintuple > > checked! Has multipathd been changed so it cannot read anything from > > disk even if invoked from within bash? Thanks - John > -- > John A. Sullivan III > Open Source Development Corporation > +1 207-985-7880 > jsullivan opensourcedevel com > > > Making Christianity intelligible to secular society > > > -- > dm-devel mailing list > dm-devel redhat com > | http://www.redhat.com/archives/dm-devel/2009-April/msg00153.html | CC-MAIN-2014-35 | refinedweb | 1,124 | 62.98 |
Pillow supports drawing text on your images in addition to shapes. Pillow uses its own font file format to store bitmap fonts, limited to 256 characters. Pillow also supports TrueType and OpenType fonts as well as other font formats supported by the FreeType library.
In this chapter, you will learn about the following:
- Drawing Text
- Changing Text Color
- Drawing Multiple Lines of Text
- Aligning Text
- Changing Text Opacity
- Learning About Text Anchors
While this article is not completely exhaustive in its coverage of drawing text with Pillow, when you have finished reading it, you will have a good understanding of how text drawing works and be able to draw text on your own.
Let’s get started by learning how to draw text.
Drawing Text
Drawing text with Pillow is similar to drawing shapes. However, drawing text has the added complexity of needing to be able to handle fonts, spacing, alignment, and more. You can get an idea of the complexity of drawing text by taking a look at the
text() function’s signature:
def text(xy, text, fill=None, font=None, anchor=None, spacing=4, align='left', direction=None, features=None, language=None, stroke_width=0, stroke_fill=None, embedded_color=False)
This function takes in a lot more parameters than any of the shapes you can draw with Pillow! Let’s go over each of these parameters in turn:
xy– The anchor coordinates for the text (i.e. where to start drawing the text).
text– The string of text that you wish to draw.
fill– The color of the text (can a tuple, an integer (0-255) or one of the supported color names).
font– An
ImageFontinstance.
anchor– The text anchor alignment. Determines the relative location of the anchor to the text. The default alignment is top left.
spacing– If the text is passed on to
multiline_text(), this controls the number of pixels between lines.
align– If the text is passed on to
multiline_text(),
"left",
"center"or
"right". Determines the relative alignment of lines. Use the anchor parameter to specify the alignment to
xy.
direction– Direction of the text. It can be
"rtl"(right to left),
"ltr"(left to right) or
"ttb"(top to bottom). Requires libraqm.
features– A list of OpenType font features to be used during text layout. Requires libraqm.
language– The language of the text. Different languages may use different glyph shapes or ligatures. This parameter tells the font which language the text is in, and to apply the correct substitutions as appropriate, if available. It should be a BCP 47 language code. Requires libraqm.
stroke_width– The width of the text stroke
stroke_fill– The color of the text stroke. If you don’t set this, it defaults to the
fillparameter’s value.
embedded_color– Whether to use font embedded color glyphs (COLR or CBDT).
You probably won’t use most of these parameters are on a regular basis unless your job requires you to work with foreign languages or arcane font features.
When it comes to learning something new, it’s always good to start with a nice example. Open up your Python editor and create a new file named
draw_text.py. Then add this code to it:
# draw_text.py from PIL import Image, ImageDraw, ImageFont def text(output_path): image = Image.new("RGB", (200, 200), "green") draw = ImageDraw.Draw(image) draw.text((10, 10), "Hello from") draw.text((10, 25), "Pillow",) image.save(output_path) if __name__ == "__main__": text("text.jpg")
Here you create a small image using Pillow’s
Image.new() method. It has a nice green background. Then you create a drawing object. Next, you tell Pillow where to draw the text. In this case, you draw two lines of text.
When you run this code, you will get the following image:
That looks pretty good. Normally, when you are drawing text on an image, you would specify a font. If you don’t have a font handy, you can use the method above or you can use Pillow’s default font.
Here is an example that updates the previous example to use Pillow’s default font:
# draw_text_default_font.py from PIL import Image, ImageDraw, ImageFont def text(output_path): image = Image.new("RGB", (200, 200), "green") draw = ImageDraw.Draw(image) font = ImageFont.load_default() draw.text((10, 10), "Hello from", font=font) draw.text((10, 25), "Pillow", font=font) image.save(output_path) if __name__ == "__main__": text("text.jpg")
n this version of the code, you use
ImageFont.load_default() to load up Pillow’s default font. Then you apply the font to the text, you pass it in with the
font parameter.
The output of this code will be the same as the first example.
Now let’s discover how to use a TrueType font with Pillow!
Pillow supports loading TrueType and OpenType fonts. So if you have a favorite font or a company mandated one, Pillow can probably load it. There are many open source TrueType fonts that you can download. One popular option is Gidole, which you can get here:
The Pillow package also comes with several fonts in its test folder. You can download Pillow’s source here:
This book’s code repository on Github includes the Gidole font as well as a handful of the fonts from the Pillow tests folder that you can use for the examples in this chapter:
To see how you can load up a TrueType font, create a new file and name it
draw_truetype.py. Then enter the following:
# draw_truetype.py from PIL import Image, ImageDraw, ImageFont def text(input_image_path, output_path): image = Image.open(input_image_path) draw = ImageDraw.Draw(image) y = 10 for font_size in range(12, 75, 10): font = ImageFont.truetype("Gidole-Regular.ttf", size=font_size) draw.text((10, y), f"Chihuly Exhibit ({font_size=}", font=font) y += 35 image.save(output_path) if __name__ == "__main__": text("chihuly_exhibit.jpg", "truetype.jpg")
For this example, you use the Gidole font and load an image taken at the Dallas Arboretum in Texas:
Then you loop over several different font sizes and write out a string at different positions on the image. When you run this code, you will create an image that looks like this:
That code demonstrated how to change font sizes using a TrueType font. Now you’re ready to learn how to switch between different TrueType fonts.
Create another new file and name this one
draw_multiple_truetype.py. Then put this code into it:
# draw_multiple_truetype.py import glob from PIL import Image, ImageDraw, ImageFont def truetype(input_image_path, output_path): image = Image.open(input_image_path) draw = ImageDraw.Draw(image) y = 10 ttf_files = glob.glob("*.ttf") for ttf_file in ttf_files: font = ImageFont.truetype(ttf_file, size=44) draw.text((10, y), f"{ttf_file} (font_size=44)", font=font) y += 55 image.save(output_path) if __name__ == "__main__": truetype("chihuly_exhibit.jpg", "truetype_fonts.jpg")
Here you use Python’s
glob module to search for files with the extension
.ttf. Then you loop over those files and write out the font name on the image using each of the fonts that
glob found.
When you run this code, your new image will look like this:
This demonstrates writing text with multiple formats in a single code example. You always need to provide a relative or absolute path to the TrueType or OpenType font file that you want to load. If you don’t provide a valid path, a
FileNotFoundError exception will be raised.
Now let’s move on and learn how to change the color of your text!
Changing Text Color
Pillow allows you to change the color of your text by using the
fill parameter. You can set this color using an RGB tuple, an integer or a supported color name.
Go ahead and create a new file and name it
text_colors.py. Then enter the following code into it:
# text_colors.py from PIL import Image, ImageDraw, ImageFont def text_color(output_path): image = Image.new("RGB", (200, 200), "white") draw = ImageDraw.Draw(image) colors = ["green", "blue", "red", "yellow", "purple"] font = ImageFont.truetype("Gidole-Regular.ttf", size=12) y = 10 for color in colors: draw.text((10, y), f"Hello from Pillow", font=font, fill=color) y += 35 image.save(output_path) if __name__ == "__main__": text_color("colored_text.jpg")
In this example, you create a new white image. Then you create a list of colors. Next, you loop over each color in the list and apply the color using the
fill parameter.
When you run this code, you will end up with this nice output:
This output demonstrates how you can change the color of your text.
Now let’s learn how to draw multiple lines of text at once!
Drawing Multiple Lines of Text
Pillow also supports drawing multiple lines of text at once. In this section, you will learn two different methods of drawing multiple lines. The first is by using Python’s newline character:
n.
To see how that works, create a file and name it
draw_multiline_text.py. Then add the following code:
# draw_multiline_text.py from PIL import Image, ImageDraw, ImageFont def text(input_image_path, output_path): image = Image.open(input_image_path) draw = ImageDraw.Draw(image) font = ImageFont.truetype("Gidole-Regular.ttf", size=42) text = "Chihuly ExhibitnDallas, Texas" draw.text((10, 25), text, font=font) image.save(output_path) if __name__ == "__main__": text("chihuly_exhibit.jpg", "multiline_text.jpg")
For this example, you create a string with the newline character inserted in the middle. When you run this example, your result should look like this:
Pillow has a built-in method for drawing multiple lines of text too. Take the code you wrote in the example above and copy and paste it into a new file. Save your new file and name it
draw_multiline_text_2.py.
Now modify the code so that it uses the
multiline_text() function:
# draw_multiline_text_2.py from PIL import Image, ImageDraw, ImageFont def text(input_image_path, output_path): image = Image.open(input_image_path) draw = ImageDraw.Draw(image) font = ImageFont.truetype("Gidole-Regular.ttf", size=42) text = """ Chihuly Exhibit Dallas, Texas""" draw.multiline_text((10, 25), text, font=font) image.save(output_path) if __name__ == "__main__": text("chihuly_exhibit.jpg", "multiline_text_2.jpg")
In this example, you create a multiline string using Python’s triple quotes. Then you draw that string onto your image by calling
multiline_text().
When you run this code, your image will be slightly different:
The text is positioned down and to the right of the previous example. The reason is that you used Python’s triple quotes to create the string. It retains the newline and indentation that you gave it. If you put this string into the previous example, it should look the same.
The
multiline_text() doesn’t affect the end result.
Now let’s learn how you can align text when you draw it.
Aligning Text
Pillow lets you align text. However, the alignment is relative to the anchor and applies to multiline text only. You will look at an alternative method for aligning text without using the
align parameter in this section as well.
To get started with
align, create a new file and name it
text_alignment.py. Then add the following code:
# text_alignment.py from PIL import Image, ImageDraw, ImageFont def alignment(output_path): image = Image.new("RGB", (200, 200), "white") draw = ImageDraw.Draw(image) alignments = ["left", "center", "right"] y = 10 font = ImageFont.truetype("Gidole-Regular.ttf", size=12) for alignment in alignments: draw.text((10, y), f"Hello fromn Pillow", font=font, align=alignment, fill="black") y += 35 image.save(output_path) if __name__ == "__main__": alignment("aligned_text.jpg")
Here you create a small, white image. Then you create a list of all of the valid alignment options: “left”, “center”, and “right”. Next, you loop over these alignment values and apply them to the same multiline string.
After running this code, you will have the following result:
Looking at the output, you can kind of get a feel for how alignment works in Pillow. Whether or not that works for your use-case is up for you to decide. You will probably need to adjust the location of where you start drawing in addition to setting the
align parameter to get what you really want.
You can use Pillow to get the size of your string and do some simple math to try to center it though. You can use either the Drawing object’s
textsize() method or the font object’s
getsize() method for that.
To see how that works, you can create a new file named
center_text.py and put this code into it:
# center_text.py from PIL import Image, ImageDraw, ImageFont def center(output_path): width, height = (400, 400) image = Image.new("RGB", (width, height), "grey") draw = ImageDraw.Draw(image) font = ImageFont.truetype("Gidole-Regular.ttf", size=12) text = "Pillow Rocks!" font_width, font_height = font.getsize(text) new_width = (width - font_width) / 2 new_height = (height - font_height) / 2 draw.text((new_width, new_height), text, fill="black") image.save(output_path) if __name__ == "__main__": center("centered_text.jpg")
In this case, you keep track of the image’s size as well as the string’s size. For this example, you used
getsize() to get the string’s width and height based on the the font and the size of the font.
Then you took the image width and height and subtracted the width and height of the string and divided by two. This should get you the coordinates you need to write the text in the center of the image.
When you run this code, you can see that the text is centered pretty well:
However, this starts to fall about as you increase the size of the font. The more you increase it, the further off-center it is. There are several alternative solutions on StackOverflow here:
The main takeaway though is that you will probably end up needing to calculate your own offset for the font that you are using. Typesetting is a complicated business, after all.
Now let’s find out how to change your text’s opacity!
Changing Text Opacity
Pillow supports changing the text’s opacity as well. What that means is that you can make the text transparent, opaque or somewhere in between. This only works with images that have an alpha channel.
For this example, you will use this flower image:
Now create a new file and name it
text_opacity.py. Then add the following code to your new file:
# text_opacity.py from PIL import Image, ImageDraw, ImageFont def change_opacity(input_path, output_path): base_image = Image.open(input_path).convert("RGBA") txt_img = Image.new("RGBA", base_image.size, (255,255,255,0)) font = ImageFont.truetype("Gidole-Regular.ttf", 40) draw = ImageDraw.Draw(txt_img) # draw text at half opacity draw.text((10,10), "Pillow", font=font, fill=(255,255,255,128)) # draw text at full opacity draw.text((10,60), "Rocks!", font=font, fill=(255,255,255,255)) composite = Image.alpha_composite(base_image, txt_img) composite.save(output_path) if __name__ == "__main__": change_opacity("flowers_dallas.png", "flowers_opacity.png")
In this example, you open the flower image and convert it to RGBA. Then you create a new image that is the same size as the flower image. Next, you load the Gidole font and create a drawing context object using the custom image you just created.
Now comes the fun part! You draw one string and set the alpha value to 128, which equates to about half opacity. Then you draw a second string on the following line and tell Pillow to use full opacity. Note that in both of these instances, you are using RGBA values rather than color names, like you did in your previous code examples. This gives you more versatility in setting the alpha amount.
The last step is to call
alpha_composite() and composite the
txt_img onto the
base_image.
When you run this code, your output will look like this:
This demonstrates how you can change the opacity of your text with Pillow. You should try a few different values for your
txt_img to see how it changes the text’s opacity.
Now let’s learn what text anchors are and how they affect text placement.
Learning About Text Anchors
You can use the
anchor parameter to determine the alignment of your text relative to the
xy coordinates you give. The default is top-left, which is the
la (left-ascender) anchor. According to the documentation,
la means left-ascender aligned text.
The first letter in an anchor specifies it’s horizontal alignment while the second letter specifies its vertical alignment. In the next two sub-sections, you will learn what each of the anchor names mean.
Horizontal Anchor Alignment
There are four horizontal anchors. The following is an adaptation from the documentation on horizontal anchors:
l(left) – Anchor is to the left of the text. When it comes to horizontal text, this is the origin of the first glyph.
m(middle) – Anchor is horizontally centered with the text. In the case of vertical text you should use
s(baseline) alignment instead, as it doesn’t change based on the specific glyphs used in the text.
r(right) – Anchor is to the right of the text. For horizontal text this is the advanced origin of the last glyph.
s– baseline (vertical text only). For vertical text this is the recommended alignment, because it doesn’t change based on the specific glyphs of the given text
Vertical Anchor Alignment
There are six vertical anchors. The following is an adaptation from the documentation on vertical anchors:
a(ascender / top) – (horizontal text only). Anchor is at the ascender line (top) of the first line of text, as defined by the font.
t(top) — (single-line text only). Anchor is at the top of the text. For vertical text this is the origin of the first glyph. For horizontal text it is recommended to use a (ascender) alignment instead, because it won’t change based on the specific glyphs of the given text.
m(middle) – Anchor is vertically centered with the text. For horizontal text this is the midpoint of the first ascender line and the last descender line.
s— baseline (horizontal text only). Anchor is at the baseline (bottom) of the first line of text, only descenders extend below the anchor.
b(bottom) – (single-line text only). Anchor is at the bottom of the text. For vertical text this is the advanced origin of the last glyph. For horizontal text it is recommended to use
d(descender) alignment instead, because it won’t change based on the specific glyphs of the given text.
d(descender / bottom) – (horizontal text only). Anchor is at the descender line (bottom) of the last line of text, as defined by the font.
Anchor Examples
Anchors are hard to visualize if all you do is talk about them. It helps a lot if you create some examples to see what really happens. Pillow provides an example in their documentation on anchors along with some very helpful images:
You can take their example and adapt it a bit to make it more useful. To see how, create a new file and name it
create_anchor.py. Then add this code to it:
# create_anchor.py from PIL import Image, ImageDraw, ImageFont def anchor(xy=(100, 100), anchor="la"): font = ImageFont.truetype("Gidole-Regular.ttf", 32) image = Image.new("RGB", (200, 200), "white") draw = ImageDraw.Draw(image) draw.line(((0, 100), (200, 100)), "gray") draw.line(((100, 0), (100, 200)), "gray") draw.text((100, 100), "Python", fill="black", anchor=anchor, font=font) image.save(f"anchor_{anchor}.jpg") if __name__ == "__main__": anchor(anchor)
You can run this code as-is. The default anchor is “la”, but you explicitly call that out here. You also draw a cross-hair to mark where the
xy position is. If you run this with other settings, you can see how the anchor affects it.
Here is a screenshot from six different runs using six different anchors:
You can try running this code with some of the other anchors that aren’t shown here. You can also adjust the position tuple and re-run it again with different anchors. You could even create a loop to loop over the anchors and create a set of examples if you wanted to.
Wrapping Up
At this point you have a good understanding of how to draw text using Pillow. In fact, you learned how to do all of the following:
- Drawing Text
- Changing Text Color
- Drawing Multiple Lines of Text
- Aligning Text
- Changing Text Opacity
- Learning About Text Anchors
- Creating a Text Drawing GUI
You can now take what you have learned and practice it. There are lots of examples in this article that you can use as jumping off points to create new applications!
2 thoughts on “Mike Driscoll: Drawing Text on Images with Pillow and Python”
Originally I was worried about something bad, but when I got it, I was completely worried. The five-star praise is very natural.
My brother suggested I might like this website. He
was totally right. This submit actually made my day. You can not consider simply how so much time I had spent for this info!
Thanks! | https://www.coodingdessign.com/python/mike-driscoll-drawing-text-on-images-with-pillow-and-python/ | CC-MAIN-2021-10 | refinedweb | 3,480 | 58.99 |
Framework for Context-Sensitive Help Pages
Project description
This package provides a framework for creating help pages for Zope 3 applications. ZCML directives are used to minimize the overhead of creating new help pages.
Documentation is hosted at
CHANGES
4.1.0 (2017-07-12)
- The help namespace no longer modifies the global help object on traversal. Instead it returns a new proxy object. This makes it thread-safe. See issue 4.
- getTopicFor now really returns the first found topic in the event that the object implements multiple interfaces that have registered topics for the given view. Previously it would return the topic for the least-specific interface.
4.0.1 (2017-05-21)
- Drop test dependency on zope.app.securitypolicy. It wasn’t used, and it isn’t yet fully ported to Python 3.
4.0.0 (2017-05-17)
- Add support for Python 3.4, 3.5, 3.6 and PyPy.
- Change ZODB dependency to persistent.
- Drop test dependency on zope.app.testing, zope.app.zcmlifiles and zope.app.apidoc, among others.
3.5.2 (2010-01-08)
- Fix tests using a newer zope.publisher that requires zope.login.
3.5.1 (2009-03-21)
- Use zope.site instead of zope.app.folder.
3.5.0 (2009-02-01)
- Removed OnlineHelpTopicFactory, simple and SimpleViewClass. All of them where using old deprecated and removed Zope3 imports. None of them where used and tested.
- Use zope.container instead of zope.app.container.
- Removed use of zope.app.zapi.
3.4.1 (2007-10-25)
- Package meta-data update.
3.4.0 (2007-10-23)
- Initial release independent of the main Zope tree.
Older
Project details
Release history Release notifications
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages. | https://pypi.org/project/zope.app.onlinehelp/ | CC-MAIN-2018-34 | refinedweb | 300 | 54.9 |
Use this guide to quickly start a basic call with the Agora SDK for Electron.
Sample project
We provide an open-source sample project that implements Agora Electron Quickstart on GitHub. You can download it and view the source code.
Prerequisites
- Node.js 6.9.1 or later
- Electron 1.8.3 or later
npm install -D --arch=ia32 electronto install a 32-bit Electron. Otherwise you may receive the error:
Not a valid win32 application.
Set up the development environment
In this section, we will create an Electron project, integrate the SDK into the project, and install the dependency to prepare the development environment.
Create a project
Follow the steps in Writing Your First Electron App to create an Electron project. Skip to Integrate the SDK if a project already exists.
Integrate the SDK
Choose either of the following methods to integrate the Agora SDK into your project.
Method 1: Install the SDK through npm
Go to the project path, and run the following command line to install the latest version of the Electron SDK:
npm install agora-electron-sdk
Import the SDK into your project with the following code:
import AgoraRtcEngine from 'agora-electron-sdk'
Method 2: Download the SDK from the Developer Portal
Go to SDK Downloads to download the Agora SDK for Electron.
Save the downloaded SDk package into the root directory of your project file.
Import the SDK into your project with the following code:
import AgoraRtcEngine from './agora-electron-sdk/AgoraSdk.js'
Switch the prebuild add-on version
By default, Agora uses Electron 1.8.3 to build the project. Switch the prebuilt add-on version in the .npmrc file according to your Electron version:
is compiled from Nodejs version 54, this version requires Nodejs version 64.
// Downloads a prebuilt add-on with Electron 1.8.3 agora_electron_dependent = 1.8.3 // Downloads a prebuilt add-on with Electron 3.0.6 agora_electron_dependent = 3.0.6 // Downloads a prebuilt add-on With Electron 4.2.8 agora_electron_dependent = 4.2.8 // Downloads a prebuilt add-on With Electron 5.0.8 agora_electron_dependent = 5.0.8
Install the dependency
Under the project path, run
npm install to install the dependency and trigger the npm run download command. You can also install the dependency manually.
If you want to debug with Xcode or Visual Studio, run
npm run debug to generate project files and SDK files for the debug environment.
You have now integrated the Agora SDK for Electron into your project.
Implement the basic call
Refer to the Agora Electron Quickstart demo project to implement various real-time communication functions in your project.
Open-source SDK
The Agora SDK for Electron is open-source on GitHub. You can download it and refer to the source code. Agora welcomes contributions from developers to improve the usability of the Electron SDK.
You can also | https://docs.agora.io/en/Video/start_call_electron?platform=Electron | CC-MAIN-2020-40 | refinedweb | 475 | 58.58 |
The state of JavaScript modules
.
An ancient fear
Most frontend developers still remember the dark days of JavaScript dependency management. Back then, you would copy and paste a library into a vendor folder, rely on global variables, try to concat everything in the right order and still would had to deal with namespace issues.
Over the past years, we’ve learned to appreciate the value of a common module format and a centralized module registry.
Today, it is easier than ever to both publish and consume a JavaScript library. It‘s literally just an
npm publish and
npm install away. That’s why people get nervous when they hear about compatibility issues between different module systems: They are afraid to lose this comfort.
In the following post, I will explain and summarize the current state of implementations and why I think that the transition to ES modules (ESM) will not harm the Node.js ecosystem. In the end, I will outline what these changes will mean for webpack users and module authors.
Current implementations
There are currently three implementations of ESM in the wild:
- In current browsers
- With webpack or similar build tools
- In Node.js (not finished yet, but probably behind a flag at the end of this year)
In order to understand the current discussion, it is important to know that ES2015 introduced two different modes:
scriptfor regular scripts with a global namespace
modulefor modular code with explicit imports and exports
If you try to use the
import or
export statement inside a
script, it will raise a
SyntaxError. These statements just make no sense in a global context. On the other hand, the
module mode implies strict mode, which forbids certain language features, such as the
with statement. Hence, it is necessary to define the mode before the script is parsed and executed.
ESM in browsers
As of May 2017, all major browsers have shipped a working implementation of ESM. Most of them are still behind a flag, though. I won’t go much into detail because Jake Archibald has already written a great article about it.
Besides minor difficulties, the implementation was pretty straightforward since there was previously no module system in the browser. In order to specify the
module mode, you need to add the
type="module" attribute to the script tag like this:
<script type="module" src="main.js"></script>
Inside a module, you can currently only use valid URLs as module specifiers. A module specifier is the string that you use to require or import other modules. In order to ensure future compatibility with CJS module specifiers, “bare” import specifiers, such as
import "lodash", are not supported yet. A module specifier must either be an absolute URL or start with
/,
./ or
../:
// Supported:
import {foo} from '';
import {foo} from '/utils/bar.js';
import {foo} from './bar.js';
import {foo} from '../bar.js';
// Not supported:
import {foo} from 'bar.js';
import {foo} from 'utils/bar.js';
// Example from
It is also important to note that once you are inside a module, every import will also be parsed as
module. There is no way to
import a
script.
ESM with webpack
Build tools like webpack usually try to parse the code with the
module mode. If anything goes wrong, they fall back to
script. The result of these tools is a
script and usually a module runtime which simulates both the behavior of CJS and ESM to a certain degree.
Let’s take these two simple ESMs for example:
webpack uses function wrappers to encapsulate the module scope and object references to simulate ESM live bindings. Once per compilation it also includes a module runtime which is responsible for bootstrapping and caching the modules. Additionally, it translates module specifiers into numeric module ids. This reduces both the bundle size and the time to bootstrap.
What does that mean? Let’s take a look at the compiled output:
I’ve simplified and removed some code which is not relevant for this example. As you can see, webpack replaces all the
export statements with
Object.defineProperty on the
exports object. It also replaces all references to imported values with property accessors. Also note the
"use strict" directive at the beginning of every ESM. This was added by webpack to account for the strict mode in ESMs.
This implementation is a simulation because it tries to mimic the behavior of ESM and CJS — it does not replicate it. For instance, it falls short of certain edge cases. Take this module:
console.log(this);
If you run that through Babel with
babel-preset-es2015, you will get:
“use strict”;
console.log(undefined);
Judging from the output, it looks like Babel assumes ESM by default, because the
module mode implies strict mode and initializes
this with
undefined.
With webpack, however, you will get:
(function(module, exports) {
console.log(this);
})
When bootstrapped,
this will point to
exports which matches the behavior of CJS in Node.js. This is because the grammar of
script and
module is ambiguous. Parsers cannot tell whether that module is an ESM or CJS. And when in doubt, webpack simulates CJS because that is still the most popular module style.
This simulation works in a lot of cases because module authors usually avoid this kind of code. However, “a lot of cases” is not sufficient for a platform like Node.js where all valid JavaScript code is supposed to run.
ESM in Node.js
Node.js is having troubles implementing ESM because it still needs to support CJS. The syntax looks similar, but the runtime behavior is entirely different. James M Snell, member of the Node.js Core Technical Committee (CTC), has written an excellent article that explains the differences between CJS and ESM.
It boils down to the fact that CJS is a dynamic module system and ESM is a static one.
CJS
- Allows dynamic synchronous
require()
- Exports are only known after evaluating the module
- Exports can be added, replaced and removed even after the module has initialized
ESM
- Only allows static synchronous
import
- Imports and exports are linked before evaluating the module
- Imports and exports are immutable
Since CJS is older than ES2015, it has always been parsed in
script mode. The encapsulation is achieved by using a function wrapper. If you load a CJS in Node.js, it actually executes code similar to this:
The problem arises when you want to integrate both module systems into the same runtime. Cyclic dependencies between ESM and CJS, for instance, can quickly lead to a deadlock-like situation.
However, getting rid of CJS support was not an option either, due to the high number of existing CJS modules. In order to avoid a disruption of the Node.js ecosystem, it was clear that:
- existing CJS code must continue to work the same way
- both module systems must work simultaneously and as seamlessly as possible
The current trade-offs
In March 2017, after months of discussions, the CTC finally found a way to make that happen. Since seamless integration was not possible without changes to the ES specification and engines, the CTC decided to start with an implementation that comes with some trade-offs:
1. ESM must have the
*.mjs file extension
This is due to the ambiguous grammar issue as explained above. You can’t know for sure what kind of JavaScript code you’re looking at just by parsing it. With backwards compatibility being a primary goal for Node.js, the author needs to opt-in into the new mode. There have been various discussions about alternatives, but a different file extension is the solution with the best trade-off.
2. CJS can only import ESM via asynchronous
import()
Node.js will load ESMs asynchronously in order to match the browser behavior as close as possible. Hence, a synchronous
require() of an ESM will not be possible. As a consequence, every function that depends on an ESM needs to be asynchronous:
3. CJS exposes a single, immutable default export to ESM
Using Babel or webpack, we usually refactored CJS to ESM like this:
// CJS
const { a, b } = require("c");
// ESM
import { a, b } from "c";
Again, the syntax looks pretty similar, but it ignores the fact that there are no named exports in CJS. There is just a single export called
default which equals an immutable snapshot of
module.exports when the CJS module has finished evaluating. Technically, it would be possible to destructure
module.exports into named imports, but that would require a bigger change in the specification. That’s why the CTC has decided to go this route for now.
4. Module-scoped variables like
module,
require and
__filename do not exist in ESM
Node.js and browsers will implement counterparts for some of them in ESM, but the standardization process is still ongoing.
Given the engineering challenges that come with the integration of CJS and ESM into a single runtime, the CTC has done an incredibly good job evaluating the edge cases and trade-offs. For instance, using a different file extension is a very simple solution to this problem.
In fact, a file extension is basically a hint on how a binary file should be interpreted. If a
module is not a
script, we should use a different file extension. Other tools like linters or IDEs can pick up the same information.
Sure, the introduction of a new file extension comes with a cost, but once servers and other applications have acknowledged
*.mjs as JavaScript, we will soon forget the dispute.
Will *.mjs be the Python 3 of Node.js?
With all these constraints in mind, one might ask what damage this transition will cause to the ecosystem. Although the CTC has worked hard to iron out the rough spots, there is still a lot of uncertainty regarding how the community will adopt it. This uncertainty is underscored by the claim by well-known NPM module authors that they will never use
*.mjs in their modules.
It’s hard to predict how the community is going to react, but I don’t think that we will see a big disruption of the ecosystem. I even think that we will see a smooth transition from CJS to ESM. This is mainly because of two reasons:
1. Strict backwards compatibility with CJS
Module authors that are not comfortable with ESM can still stick to CJS without being excluded. Their own code will not be affected by the adoption of ESM which reduces the likelihood of them moving to another runtime. It also eases the transition which can take some time in an ecosystem of NPM’s size. Refactoring from CJS to ESM puts a burden on package maintainers and I don’t expect all of them to have time for this.
2. Seamless integration of CJS in ESM
Importing a CJS module from ESM is pretty straight-forward. All you need to remember is that CJS exports only a single default value. Once you’re inside an ESM, you probably won’t even notice what module style your dependencies are using. Compare that with
await import() from CJS.
Because of this and other advantages of ESM, such as tree shaking and browser compatibility out of the box, I expect to see a slow and steady transition to ESM over the next couple of years. CJS-only features, like dynamic
require() and monkey-patchable exports, have always been controversial in the Node.js community and will not outweigh the benefits of ESM.
What does this all mean for me?
With all the recent events, it is easy to become confused by all the options and constraints. In the following section, I’ve compiled typical questions that developers will face and my answers for them:
Do I need to refactor my existing code now?
No. Node.js has just started to implement ESM and there is still a lot of work to be done. James M Snell expects that it will still take a year at least and there’s still room for changes, so it is not safe to refactor now.
Should I use ESMs in my new code?
- If you already have a build step like a webpack build or if you’re comfortable with having one, yes. It will ease the transition of your codebase and makes tree shaking possible. But beware: you will probably need to refactor some parts of it once Node.js has native ESM support.
- If you’re writing a library, yes. Users of your module will benefit from tree shaking.
- If you do not want to have a build step or if you’re writing a Node.js app, stick to CJS.
Should I use .mjs for ESMs now?
No. There’s currently no benefit of it and tooling support is still weak. I recommend to start the transition as soon as native ESM support lands in Node.js. Remember that browsers do only care about MIME types, not file extension.
Should I care about native browser compatibility?
Yes, to some extent. You should not omit the
.js extension in your import statements anymore because browsers need full URLs. They will not be able to perform a path lookup like Node.js does. Similarly, you should avoid
index.js files. However, I don’t expect that people will start to use NPM packages in the browser anytime soon because bare imports are still not possible.
What should I ship as a library author?
Write ESM and use Rollup or webpack to transpile it down to a single CJS module. Point the
main field inside your
package.json to this CJS bundle. Additionally, use the
module field to point to your original ESMs. If you’re using new language features besides ESM, you should compile it down to ES5 and provide both a CJS and an ESM bundle. This way, users of your library can still profit from tree shaking while not having to transpile your code.
Summary
There is a lot of uncertainty concerning ES modules. Because of the trade-offs made by the current Node.js implementation, developers are afraid that it might disrupt the Node.js ecosystem.
There are good chances that this is not going to happen because of two reasons: Strict backwards compatibility for CJS and seamless integration of CJS in ESM.
Until Node.js has shipped native ESM support, you should still use tools like Rollup and webpack. They simulate an ESM environment to a certain degree. Be aware that they are not fully spec compliant. Besides that, there are also good reasons for still using bundlers once we can use NPM packages in browsers.
We, the webpack team, are working hard to make that transition for you as smooth as it can be. In order to make that possible, we are planning to simulate Node.js’ way of importing CJS once ESM support in Node.js is mature. | https://medium.com/webpack/the-state-of-javascript-modules-4636d1774358?source=---------2------------------ | CC-MAIN-2019-26 | refinedweb | 2,485 | 64.81 |
A class that encapsulates a newick string description of a tree and metadata about the tree. More...
#include <nxstreesblock.h>
A class that encapsulates a newick string description of a tree and metadata about the tree.
the NxsTreesBlock stores the trees as NxsFullTreeDescription because during its parse and validation of a tree string. By default, NCL will "process" each tree -- converting the taxon labels to numbers for the taxa (the number will be 1 + the taxon index). During this processing, the trees block detects things about the tree such as whether there are branch lengths on the tree, whether there are polytomies...
This data about the tree is then stored in a NxsFullTreeDescription so that the client code can access some information about a tree before it parses the newick string.
If you do not want to parse the newick string yourself, you can construct a NxsSimpleTree object from a NxsFullTreeDescription object if the NxsFullTreeDescription is "processed"
If the NxsTreesBlock is configured NOT to process trees (see NxsTreesBlock::SetProcessAllTreesDuringParse())
Definition at line 383 of file nxstreesblock.h. | http://phylo.bio.ku.edu/ncldocs/v2.1/funcdocs/classNxsFullTreeDescription.html | CC-MAIN-2017-17 | refinedweb | 177 | 54.66 |
Recommended snack and song:
Sliced bananas and strawberries with granola all mixed in a bowl of natural yogurt while listening to Royal Blood.
When you hear about blockchain, you normally think of a publicly available ledger, on a worldwide distributed network of peers that have an agreement strategy to include new blocks (or transactions) on the blockchain. This is OK for most applications, but what happens when you’d like to take advantage of the blockchain technology, but don’t want your data to be scattered around in the world? What happens when there’s sensitive data that, if made public, could potentially hurt your business interests?
Enter Hyperledger Fabric: an open-source blockchain framework implementation hosted by The Linux Foundation, which you can use to host your very own and very private blockchain. You can read more about it on their website, and perhaps even watch this intro video, which makes it a bit easier to understand what the motivation behind the entire project is.
tl;dr: Go clone this repo and follow the README instructions to get this running.
This is what we’re gonna cover:
- Installing the prerequisites.
- Using the yeoman generator to get a basic business network definition project.
- Coding a simple solution with it.
- Deploying locally.
- Looking at some follow-up steps you might want to consider.
Just a quick note—this first part of the Hyperledger Tutorial series is all about getting started building business logic and having it deployed onto your own blockchain. Later blog posts in this series will take a deeper dive into the concepts that really make Hyperledger very powerful.
Installing the Prerequisites
First, make sure you have NodeJS installed (go with LTS, that’s the safest choice). If you already have, a good security measure is making sure you can do sudoless npm global installs (in case you’re using Linux or OSX).
Now, run these commands:
$ npm install -g composer-cli $ npm install -g composer-rest-server $ npm install -g composer-playground $ npm install -g yo $ npm install -g generator-hyperledger-composer
You’ll also need to download and install Docker, which you can do by going to the Docker install page and downloading the Docker Community Edition for your OS.
Once you have Docker running on your system, it’s time to run a few bash script commands:
$ mkdir ~/fabric-tools && cd $_ $ curl -O $ unzip fabric-dev-servers.zip $ ./downloadFabric.sh
This will create a directory in ~/fabric-tools, download a few provision scripts and start downloading the Hyperledger Fabric Docker containers.
One other thing—you’d benefit a lot from using VSCode to code this project up. This can be done by installing the Hyperledger Composer extension.
Generating the Business Network Definition Project
We’re going to build some small asset management software for Dr. Who so he/she can track who owns a key and even track the creation of new keys.
First, run the yeoman generator:
$ yo hyperledger-composer:businessnetwork
…which will ask the following questions (answer them as shown below):
Welcome to the business network generator ? Business network name: tardis ? Description: Key asset management system for Dr Who ? Author name: ? Author email: ? License: Apache-2.0 ? Namespace: com.gallifrey.tardis create index.js create package.json create README.md create models/com.gallifrey.tardis.cto create .eslintrc.yml create test/logic.js create lib/logic.js
Perfect! Now we have to create our models to represent our network, which will be super simple; we just need a Key asset and a Companion. Also, we need to create a TransferKey transaction to transfer the keys around. Open up the models/com.gallifrey.tardis.cto file and replace its contents with:
namespace com.gallifrey.tardis participant Companion identified by companionId { o String companionId o String name } asset Key identified by keyId { o String keyId o String owner } transaction TransferKey { --> Companion companion --> Key key }
As for the logic of the TransferKey transaction, replace the contents of lib/logic.js with:
'use strict'; var NETWORK_NAME = 'com.gallifrey.tardis'; var KEY_ASSET = 'Key'; /** * Transfer ownership of a TARDIS key to a fello * @param {com.gallifrey.tardis.TransferKey} transferKey * @transaction */ function onTransferKey(transferKey) { var key = transferKey.key; var keyFQDN = [NETWORK_NAME, KEY_ASSET].join('.'); return getAssetRegistry(keyFQDN) .then(function(registry) { key.owner = transferKey.companion; return registry.update(key); }); }
Quick note: These JS logic files inside the lib folder are NOT NodeJS modules and currently don’t support ES6 syntax. I asked and this was their answer.
Awesome, we’ve coded our first official Business Network Definition project! It’s time to deploy it locally to our Hyperledger Fabric servers:
$ cd ~/fabric-tools/ $ ./startFabric.sh # This will kickstart the fabric servers. $ ./createPeerAdminCard.sh # This will create a peer admin user
The peer admin user takes care of deploying the business network definitions to the peers. For the purposes of this tutorial, we’re gonna have one peer admin card to rule all the peers.
Build Code for Deployment
Once you have your business network definition done, and you’ve made sure your servers are up and operational, we can proceed with building our BNA (business network archive) file by navigating the console to your project’s folder and running:
$ composer archive create -t dir -n .
Then we need to install our business network as a runtime for the peer:
$ composer runtime install --card PeerAdmin@hlfv1 --businessNetworkName tardis
Next up, we need to create a network admin card and deploy our previously generated .bna file:
$ composer network start --card PeerAdmin@hlfv1 --networkAdmin admin --networkAdminEnrollSecret adminpw --archiveFile tardis@0.0.1.bna --file networkadmin.card
Make sure you change the parameters accordingly; for instance, the name of the .bna file may change depending on the version of the project in the package.json file.
Now we need to import the generated networkadmin.card card file by typing:
$ composer card import --file networkadmin.card
And just to check that everything is up and running:
$ composer network ping --card admin@tardis
For us to take a look at the final result of what we’ve accomplished, there’s a tool we’ve installed called Composer Playground, which we can launch by doing:
$ composer-playground -p 5000
In there, you can play around with your data; you can also launch a small REST server for you to play around with the data, which is built on top of Loopback:
$ composer-rest-server -c admin@tardis -n never -p 9000
Now you have a complete blockchain-based business network using Hyperledger running on your computer using Docker! How cool is that? For the next parts of this tutorial, we’re going to take a deep dive into more complex concepts that will give you a better perspective on how to apply this technology in your applications.
| https://gorillalogic.com/blog/hyperledger-fabric-developer-tutorial-part-1-make-your-own-blockchain/ | CC-MAIN-2019-51 | refinedweb | 1,128 | 53.71 |
PyJoke 0.3.0
PyJoke: Fetch your jokes in Python.
PyJoke
===========
PyJoke is a package for fetching the perfect joke in a database.
You give a sentence, you get a joke. Isn't that great? Common usage is::
#!/usr/bin/env python
from pyjoke.PyJoke import *
p = PyJoke()
p.changeParams() # To change the parameters on the fly
print p.getTheJoke("keywords listed as such")
PyJoke has been developed for as a NAO module (in French), but can also work as a standalone.
It should be possible to make it work in English.
### How does it work?
* Give a sentence to PyJoke (see script above)
* PyJoke will analyse the sentence
* First, create a keywords list (by removing stopwords)
* If POSTAG is active, it will add a score to each kword
* Then, create a query, connect to database and send query
* The query (above) is meant to filter the jokes
It will get the jokes with at least 1 keyword
* Then, score each joke
* And return the best one
### What can the user change?
* Config a MySQL or a SQLite database
* Use of Postag (and the scores)
* NAO mode
* Language (French by default)
* Maximum joke length
* Conversation mode (experimental)
### Database format
The joke database needs to have two fields at least:
* text
* score
Text being the joke itself, and score being an arbitrary score that's not going to be used, really (should do that...)
### Useful libs and dependencies
PyJoke has dependencies, some are optional
* NTLK
* SQLite (or MySQL)
* YAML
* TreeTagger (opt)
* /usr/lib/sqlite3/pcre.so (opt)
- Downloads (All Versions):
- 51 downloads in the last day
- 323 downloads in the last week
- 1491 downloads in the last month
- Author: Laurent Fite
- License: LICENSE.txt
- Package Index Owner: monsieurTefi
- DOAP record: PyJoke-0.3.0.xml | https://pypi.python.org/pypi/PyJoke/0.3.0 | CC-MAIN-2015-48 | refinedweb | 294 | 79.4 |
I need to calculate the value of sin(sin...(sin(x))) for n times (n and the value of sin are input from the keyboard).
That's is what I've came up with.
#include "stdafx.h" #include <iostream> #include <math.h> using namespace std; double multipleSin(int n, double x); using namespace std; int _tmain(int argc, _TCHAR* argv[]) {double x,k; int n; cout<<"x= "; cin>>x; cout<<"n= "; cin>>n; cout<<multipleSin<<' '; //k=sin(x); //cout<<"check "<<k<<endl; system("pause"); return 0; } double multipleSin(int n, double x) { if(n>1) x=multipleSin(n-1,x); else return sin(x); }
The probles seems to be fairly simple but I can't figure it out though.
Any advise how to make this work properly? | https://www.daniweb.com/programming/software-development/threads/326037/how-does-recursion-work | CC-MAIN-2018-13 | refinedweb | 127 | 71.85 |
Associating a Task with a Future
std::packaged_task<> ties a future to the result of a function call. When the function completes, the future is ready, and the associated data is the value returned by the function. This is ideal for operations that can be subdivided into a set of self-contained tasks. These tasks can be written as functions, packaged so each task is associated with a future using
std::packaged_task, and then executed on separate threads. The driving function can then wait for the futures before processing the results of the subtasks. This lets you implement a facility similar to
std::async, but but you get to control the threads explicitly. Maybe you want all the tasks to run sequentially on the same background thread, or you want to implement a thread pool.
The template parameter for the
std::packaged_task<> class template is a function signature, like
void() for a function taking no parameters with no return value or
int(std::string&,double*) for a function that takes a non-const reference to a
std::string and a pointer to a double and returns an int. When you construct an instance of
std::packaged_task, you must pass in a function or callable object that can accept the specified parameters and that returns a type convertible to the specified return type. The types don't have to match exactly; you can construct a
std::packaged_task<double(double)> from a function that takes an int and returns a float because the types are implicitly convertible.
The return type of the function signature identifies the type of the
std::future<> returned from the
get_future() member function, and the argument list of the function signature specifies the signature of the packaged task's function call operator. For example, a partial class definition for
std::packaged_task<std::string(std::vector<char>*,int)> might look like this:
template<> class packaged_task<std::string(std::vector<char>*,int)> { public: template<typename Callable> explicit packaged_task(Callable&& f); std::future<std::string> get_future(); void operator()(std::vector<char>*,int); };
The
std::packaged_task object can be wrapped in a
std::function object, passed to a
std::thread as the thread function, passed to another function that requires a callable object, or even invoked directly. When the
std::packaged_task is invoked as a function object, the arguments supplied to the function call operator are passed to the contained function and the return value is stored as the asynchronous result in the
std::future obtained from
get_future(). This means you can wrap a task in a
std::packaged_task and retrieve the future before passing the
std::packaged_task object elsewhere to be invoked in due course. When you need the result, you simply wait for the future to become ready.
Passing Tasks Between Threads
Many GUI frameworks require that updates to the GUI be done from specific threads, so if another thread needs to update the GUI, then it must send a message to the right thread in order to do so.
std:packaged_task provides a way of doing this without requiring a custom message for each and every GUI-related activity:
#include <deque> #include <mutex> #include <future> #include <thread> #include <utility> std::mutex m; std::deque<std::packaged_task<void()> > tasks; bool gui_shutdown_message_received(); void get_and_process_gui_message(); void gui_thread() { while(!gui_shutdown_message_received()) { get_and_process_gui_message(); std::packaged_task<void()> task; { std::lock_guard<std::mutex> lk(m); if(tasks.empty()) continue; task=std::move(tasks.front()); tasks.pop_front(); } task(); } } std::thread gui_bg_thread(gui_thread); template<typename Func> std::future<void> post_task_for_gui_thread(Func f) { std::packaged_task<void()> task(f); std::future<void> res=task.get_future(); std::lock_guard<std::mutex> lk(m); tasks.push_back(std::move(task)); return res; }
This code is very simple: The GUI thread (line 12) loops until a message has been received telling the GUI to shut down (line 14), repeatedly polling for messages to handle and tasks on the task queue (line 16). If there are no tasks on the queue (line 20), then it loops again; otherwise, it extracts the task from the queue (line 22), releases the lock on the queue, and runs the task (line 25). The future associated with the task will be ready when the task completes.
Posting a task on the queue is equally simple. A new packaged task is created from the supplied function (line 34), the future is obtained from that task (line 35) by calling the
get_future() member function, and the task is put on the list (line 37) before the future is returned to the caller (line 38). The code that posted the message to the GUI thread can then wait for the future if it needs to know that the task has been completed, or it can discard the future if it doesn't need to know.
This example uses
std::packaged_task<void()>, which wraps a function or other callable object that takes no parameters and returns void. (If it returns anything else, then the return value is discarded.) This is the simplest possible task. But of course,
std::packaged_task can also be used in more complex situations. By specifying a different function signature as the template parameter, you can change the return type (and thus the type of data stored in the future's associated state) and also the argument types of the function call operator. This example could easily be extended to allow for tasks on the GUI thread to accept arguments and return values (rather than just a completion indicator) in the
std::future.
What about tasks that can't be expressed as a simple function call or tasks where the result may come from more than one place? These cases are dealt with by the third way of creating a future: using a
std::promise to set the value explicitly.
Making (std::)promises
When you have an application that needs to handle a lot of network connections, it's tempting to handle each connection on a separate thread. This can make network communication easier to think about and easier to program. It works well for low numbers of connections. Unfortunately, as the number of connections rises, this strategy becomes less suitable. As the number of threads grows, operating-system resources are consumed in large quantity. Context-switching becomes a concern. In the extreme case, the operating system may run out of resources for running new threads. In applications with very large numbers of network connections, it's therefore common to have a small number of threads (possibly only one) handling the connections, each thread dealing with multiple connections.
Consider one of these threads. Data packets will come in from the various connections being handled in essentially random order, and data packets will be queued to be sent in random order. In many cases, other parts of the application will be waiting for data to be sent or for a new batch of data to be received via a specific network connection.
std::promise<T> provides a means of setting a value (of type
T), which can later be read through an associated
std::future<T> object. A
std::promise/std::future pair represents one possible mechanism for this facility; the waiting thread could block on the future, while the thread providing the data could use the promise half of the pairing to set the associated value and make the future ready.
You can obtain the
std::future object associated with a given
std::promise by calling the
get_future() member function, just like with
std::packaged_task. When the value of the promise is set the future becomes ready and can be used to retrieve the stored value. If you destroy the
std::promise without setting a value, then an exception is stored instead. Later, I'll show you how these exceptions are transferred across threads.
Here is some thread-processing code to handle the situation just described. In this example, I used a
std::promise<bool>/std::future<bool> pair to identify the successful transmission of a block of outgoing data. The value associated with the future is a simple success/failure flag. For incoming packets, the data associated with the future is the payload of the data packet.
#include <future> void process_connections(connection_set& connections) { while(!done(connections)) { for(connection_iterator connection=connections.begin(), end=connections.end(); connection!=end; ++connection) { if(connection->has_incoming_data()) { data_packet data=connection->incoming(); std::promise<payload_type>&p=connection->get_promise(data.id); p.set_value(data.payload); } if(connection->has_outgoing_data()) { outgoing_packet data=connection->top_of_outgoing_queue(); connection->send(data.payload); data.promise.set_value(true); } } } }
The function
process_connections() loops until
done() returns
true (line 4). Every time through the loop, it checks each connection in turn (line 6), retrieving incoming data if there is any (line 11), and sending queued outgoing data (line 17). This assumes that an incoming packet has an ID and a payload. The ID is mapped to a
std::promise, perhaps by a lookup in an associative container (line 14), and the value is set to the packet's payload. For outgoing data, the packet is retrieved from the queue and sent through the connection. Once the packet has been sent, the promise associated with the outgoing data is set to true, indicating successful transmission (line 21). Whether this maps nicely to the actual network protocol depends on the protocol.
All the code up to now has completely disregarded exceptions. Although it might be nice to imagine a world in which everything works all the time, we don't live in that world. Sometimes disks fill up, sometimes what we're looking for isn't there, sometimes the network fails, and sometimes the database goes down. The C++ standard library provides a clean way to deal with exceptions in these cases and allows them to be saved as part of the associated result. | http://www.drdobbs.com/cpp/waiting-for-one-off-events-with-futures/232700082?pgno=2 | CC-MAIN-2014-52 | refinedweb | 1,622 | 50.57 |
trawick 01/06/18 05:52:22
Modified: . STATUS
Log:
prefork has had SINGLE_LISTEN_UNSERIALIZED_ACCEPT working for a long time.
Hint at what should be done in threaded to get it working there.
Revision Changes Path
1.244 +4 -4 httpd-2.0/STATUS
Index: STATUS
===================================================================
RCS file: /home/cvs/httpd-2.0/STATUS,v
retrieving revision 1.243
retrieving revision 1.244
diff -u -r1.243 -r1.244
--- STATUS 2001/06/07 10:46:12 1.243
+++ STATUS 2001/06/18 12:52:21 1.244
@@ -1,5 +1,5 @@
APACHE 2.0 STATUS: -*-text-*-
-Last modified at [$Date: 2001/06/07 10:46:12 $]
+Last modified at [$Date: 2001/06/18 12:52:21 $]
Release:
@@ -277,9 +277,9 @@
remove any old functionality. Keep everything, even if it needs
#if 0...endif wrapped to not make trouble for you.
- * Performance: Get SINGLE_LISTENER_UNSERIALIZED_ACCEPT
- optimization working again. Bill would like to see this
- working for the threaded MPM, then prefork.
+ * Performance: Get the SINGLE_LISTEN_UNSERIALIZED_ACCEPT
+ optimization working in threaded. prefork's new design for how
+ to notice data on the pod should be sufficient.
* mod_tls is very specific to OpenSSL. Make the API calls
more generic to support other encryption libraries. | http://mail-archives.apache.org/mod_mbox/httpd-cvs/200106.mbox/%3C20010618125222.34488.qmail@apache.org%3E | CC-MAIN-2015-18 | refinedweb | 199 | 63.96 |
std::[s]sizeshould behave as
std::ranges::[s]size?
std::ranges::size()and give
std::[s]size()the same semantics (but keeping them as functions and not making function objects)?
std::size(r)is not a subset of
std::ranges::size(r)right now, because the latter only considers
r.size()if that returns something integer-like and the former has no such restrictions.
std::ranges::ssize()does not work on those
sized_ranges that have non-
std::integralsize type.
std::size()cannot rely on
std::ranged::size()because sometimes std::ranges::size may use std::size() due to ADL.
Removal of wording and integration of wording fixes based on new discussion point and removal of changes to std::size / std::ssize. New discussion points have been added as point 6.0.4 under “Discussion (after R0)”.
While I think that this paper is important and should make it into C++20, the urgency and implications for breakage are significantly reduced by the new wording, because the behaviours of
std::size() and
std::ssize() are now unaffected.
Clean-up of wording and integration of wording fixes based on new discussion points. The paper body is unchanged, but new discussion points have been added as “Discussion (after R0)”.
It is my understanding that these changes are in LWG’s realm, but I will double-check with LEWG-chair to see if he wants to see this again.
While I think that this paper is important and should make it into C++20, the urgency and implications for breakage are significantly reduced by the new wording, because the behaviour of
std::size() and
std::ssize() is largely preserved for arguments that are not
sized_ranges.
Created during Belfast (Fall 2019) in response to DE269.
C++17 introduced
std::size() and C++20 will introduce
std::ssize() and
std::ranges::size(). Why do we need three and do they solve all problems in regard to size? After DE269 raised these questions, LEWG requested I write this paper.
† This can be signed under certain circumstances, but is not for any types in the standard library. Criticism of this was raised in LEWG, but this is independent of everything else and not touched by this paper to reduce last-minute impact.
std::ranges::size() was introduced (also) because it was desired that subtractable iterator-sentinel-pairs should be sufficient for a range to qualify it as a
std::ranges::sized_range. This means
std::size() will not work on certain sized ranges, but
std::ranges::size() will.
std::ssize() has been introduced (with some controversy), because there was the desire to have a signed size type that can be used (among other things) in loops and comparisons with signed counter variables. It is defined as
std::size() but casts the type to a comparable signed type. This solves the problem but only works on the subset of sized ranges that
std::size() works on.
The first problem and original intent of DE269 is that there is no signed size function that works on all sized ranges, i.e. if the arguments for adding
std::ssize() are valid, they imply that we also need
std::ranges::ssize() with the semantics of
std::ranges::size() and a cast to a signed type.
The current state is inconsistent in regard to signed vs unsigned (inside
std::ranges::).
Solution: add
std::ranges::ssize()
std::[s]sizeshould behave as
std::ranges::[s]size
During discussion in LEWG it was criticised that we have different semantics in the different namespaces at all, i.e. that the current state is inconsistent in regard to
std:: vs
std::ranges::. Because the types that
std::size() applies to is a subset of the types that
std::ranges::size() applies to, it was proposed to make them behave the same or even just have two functions instead of three or four.
It also became evident that this subsumption is only true now (before C++20), because, after C++20, ranges can opt-out of
std::ranges::size() via
disable_sized_range – but not out of
std::size(). Thus any fix in this area must happen now.
The most obvious solution would be to have
std::size() behave like
std::ranges::size(), remove the latter, and have
std::ssize() refer to
std::size(). This is not possible, however, because
std::ranges::size() is a function object and
std::size() is a function that is subject to ADL. Replacing the function with a function object will break code that relied on ADL.
The next suggested solution was to define
std::size() and
std::ssize() as functions that call their counterparts in
std::ranges::. This guarantees that if we must have more than two interfaces, at least we only have two different semantics clearly denoted by name (signed vs unsigned). Unfortunately, during discussion in LWG, it was discovered that std::ranges::size sometimes calls std::size, and LWG attendees could find no way to avoid this circularity.
With the deadline for C++20 fast approaching, changes to
std::size() and
std::ssize() were abandoned.
See above why these changes would be breaking after C++20.
See below for wording.
This is the current proposal:
Add
std::ranges::ssize(), a signed version of
std::ranges::size(), in the same way that
std::ssize() is a signed version of
std::size(). Don’t touch
std::size() and
std::ssize().
This was the previous proposal:
The discussion in LEWG also proposed the following other “solutions”:
Replace
std::[s]size with
std::ranges::[s]size. This doesn’t work because of function VS function object, see above.
Only add
std::ranges::ssize(), don’t touch
std::size() and
std::ssize(). Less invasive, but only fixes the first inconsistency.
Don’t add
std::ranges::ssize() and remove
std::ssize(). This creates some consistency with regard to the absence of any signed size function. It doesn’t solve the second inconsistency above.
Don’t add
std::ranges::ssize(), but re-define
std::ssize() in terms of
std::ranges::size() instead of
std::size. It solves the problem of a lacking ssize for all ranges. However, it increases inconsistency within
std::. And it does not solve the second inconsistency.
std::ranges::size()and give
std::[s]size()the same semantics (but keeping them as functions and not making function objects)?
Possible, but ranges authors want size functions to be function objects. The change would also be quite invasive – because
std::ranges::size() appears frequently. It’s too late to detect subtle breakage at this point.
std::size(r)is not a subset of
std::ranges::size(r)right now, because the latter only considers
r.size()if that returns something integer-like and the former has no such restrictions.
While I consider it very unlikely that code returns something not integer-like via
.size() and also depends on exposing it via
std::size() (especially since that was just introduced in C++17), changing this would break currently valid C++17 code. As such, I have changed the wording to maintain the current behaviour of
std::size() and delegate to
std::ranges::size() only for those arguments that are
sized_ranges (which is most of the arguments likely used).
std::ssize() is adapted in a similar way so that it can potentially work on types that are not
sized_ranges but that
std::size() works on.
This change means that adopting this paper after C++20 would still be possible and only “breaking” in the sense that
std::ssize() on a
sized_range could possibly return a different type in C++23 than it does in C++20.
std::ranges::ssize()does not work on those
sized_ranges that have non-
std::integralsize type.
The reason is that
static_cast<common_type_t<ptrdiff_t, make_signed_t<decltype(E)>>> is used to transform the type to signed type and this is not guaranteed to be valid for arbitrary integer-like types (that are allowed for
sized_ranges; in particular
iota_view). This shortcoming of R0 was known to the author and discussed briefly in LEWG. It was found that since this shortcoming is already part of the design of the original
std::ssize() and can be fixed after C++20, it would not be addressed now.
Casey Carter expressed dissatisfaction with this approach and proposed various resolutions – one of which I have integrated in the current wording. Note that this affects the semantics of
std::ranges::ssize() and
std::ssize() for
sized_ranges; but not
std::ssize’s fallback solution described above.
std::size()cannot rely on
std::ranged::size()because sometimes std::ranges::size may use std::size() due to ADL.
Due to possible constraint recursion the behaviour of std::size and std::ssize is no longer changed with this paper. This means certain sized_ranges are not covered by std::size and std::ssize. This may still be changed after C++20 as such a change would not be breaking.
$24.2 [range.syn]
Introduce new customization point object
$24.3 [range.access]
Introduce new §24.3.10 [range.prim.ssize] after §24.3.9 [range.prim.size]
+24.3.10 ranges::ssize + +The name ssize denotes a customization point object ([customization.point.object]). +The expression ranges::ssize(E) for a subexpression E of type T is expression-equivalent to: + +-- If range_difference_t<T> has width less than ptrdiff_t: + static_cast<ptrdiff_t>(ranges::size(E)); // [range.prim.size] +-- Otherwise: + static_cast<range_difference_t<T>>(ranges::size(E)); // [range.prim.size] | https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2020/p1970r2.html | CC-MAIN-2022-21 | refinedweb | 1,564 | 63.49 |
Can't accces to esx consolelvln Apr 21, 2016 7:32 AM
Hello,
I've upgrade my esx to ESXi-6.0.0-20160302001 profile and when I go to : I get a '404 Not Found" page.
Thanks for your help,
1. Re: Can't accces to esx consolevHaridas Apr 22, 2016 3:53 AM (in response to lvln)
have you upgraded ESXi fro prior version?
Try this
ESXi Embedded Host Client
New HTML5 Embedded Host Client for ESXi | virtuallyGhetto
2. Re: Can't accces to esx consolelvln Apr 22, 2016 4:47 AM (in response to vHaridas)
Yes, I have upgrade from 5.5U2 to 6.0.0 to 6.0U2 and I have looked at the file /etc/vmware/rhttpproxy/endpoints.conf but there was no line like "/ui local 8308 redirect allow" in it.
3. Re: Can't accces to esx consolevHaridas Apr 22, 2016 5:51 AM (in response to lvln)
In My lab, I upgrade ESXi 5.5 to ESXi 6 u2 and worked without any issue.
Enable ESXi shell or ssh and login to esxi with root/password to run below commands
can you check if esx-ui VIB is installed on your system or not?
esxcli software vib list | grep -i esx-ui
this will print vib name, version...etc. if you don't get any output means esxi-UI vib is not installed and you need to install it manually.
IF esx-vib is installed, then check if rhttpproxy service is running or not?
/etc/init.d/rhttpproxy status
if output don't say http reverse proxy is running then you can try to start http service.
/etc/init.d/rhttpproxy start.
if you still get error, please share complete error message.
Check log file for errors #more /var/log/rhttpproxy.log
Thanks,
Haridas
4. Re: Can't accces to esx consolelvln Apr 22, 2016 6:17 AM (in response to vHaridas)
I've :
esxcli software vib list | grep -i esx-ui
-> esx-ui 1.0.0-3617585 VMware VMwareCertified 2016-04-20
/etc/init.d/rhttpproxy status
-> VMware HTTP reverse proxy is running
in the /var/log/rhttpproxy.log
-> URL namespace /ui does not match any server namespace
maybe the log will ring some bells to you ..
Thks
5. Re: Can't accces to esx consolevHaridas Apr 22, 2016 6:33 AM (in response to lvln)
can you try to restart service
#/etc/init.d/rhttpproxy restart ( or stop/start)
then try to access URL.
My configuration -
# cat /etc/vmware/rhttpproxy/endpoints.conf
/ local 8309 redirect allow
/sdk local 8307 redirect allow
/client/clients.xml local 8309 allow
/folder local 8309 redirect allow
/host local 8309 redirect allow
/tmp local 8309 redirect allow
/screen local 8309 redirect allow
/guestFile local 8309 redirect allow
/cgi-bin local 8309 redirect allow
/vvold local 8090 allow allow
/ticket tickettunnel /var/run/vmware/ticket/%1 redirect allow
Try to match this file, restart proxy service again and try to access URL.
if still this don't work, uninstall esx-ui VIB and install it, then try to access URL.
Thanks,
Haridas
6. Re: Can't accces to esx consolelvln Apr 22, 2016 6:44 AM (in response to vHaridas)
Good news,
I've add the line :
/ local 8309 redirect allow
and restart the service
And I can acces the html5 web ui
Don' know why I didn't have this line. Maybe it was some restriction inside my original kickstart but I havn't locate it yet.
Thks for your help
7. Re: Can't accces to esx consolevHaridas Apr 22, 2016 6:48 AM (in response to lvln)
Good to know it worked.
Please consider awarding points for "Correct" or "Helpful" replies. Thanks....!!!
8. Re: Can't accces to esx consoleelesueur Apr 26, 2016 3:20 PM (in response to lvln)
Missing the / line in the reverse proxy is going to cause a bunch of issues related to loading of content from the host.
It's odd that it was missing, but this is the only case I have seen of this happening.
I'm glad you were able to sort it out! | https://communities.vmware.com/message/2592006 | CC-MAIN-2020-40 | refinedweb | 689 | 72.66 |
Greetings,
I'm having a problem with this code below. I want to ask 3 questions and then gather userinput into char variables. When I run the program it asks the first question and then outputs the answer. Then it asks the second question, but does not allow the user to answer the question and moves on to the last question which it does allow user input. Is there a rule about the use of multiple scanf's? Here's a screen shot:
[IMG][/IMG][IMG][/IMG]
#include <stdio.h> #include <stdlib.h> int main() { char Light; char lane; char turn; char PlayAgain = 'Y'; //while(PlayAgain == 'y') { //USER_INPUT Light Red?, Lane Right? Turn Yes?; printf("Is light red? "); scanf("%c", &Light); printf("%c", Light); //validate user input printf("Are you in the right lane? "); scanf("%c", &lane); printf("%c", lane); //validate user input printf("Are you making a turn? "); scanf("%c", &turn); printf("%c", turn); //validate user input } | https://www.daniweb.com/programming/software-development/threads/94275/multiple-scanf-s-issue | CC-MAIN-2017-43 | refinedweb | 158 | 76.52 |
Using a Wii controller with your Raspberry Pi, Gertboard, Bluetooth and Python
>>IMAGE you need more than that, you could use 3-button combos. :)
Here’s a little video of some Wiimote controlled Gertboard madness
How do you do it then?
I followed the installation instructions on Matt’s site…
And, happily, they worked first time with my Tesco’s own-brand Technika nano Bluetooth dongle, which has a Pi-compatible chipset. I bought mine in Tesco Extra for about £4.
So I think we can look forward to seeing a proliferation of Wii remote controlled Raspberry Pi programs in the near future.
What will you do with yours?
Matt’s going to control an RC car with his. After my initial Gertboard experiments, I’d like to see if it’s possible to use two controllers for an interactive Quiz.
What will you do with yours?
________________________________
* In practice, the direction controller slightly restricts the number of choices, e.g. you can’t have opposites pressed simultaneously, but we’ll ignore that.
- Technika Bluetooth USB dongle
- Technika bluetooth USB dongle
- Wii remote, Pi and Technika dongle
- This is what to look out for in Tesco
Well… that had me giggling like a maniac :-) Very cool experiments :-) And all of it run off battery, too!
Well it’s all a part of my plan to take over the world. Mwahahahahaha :rotfl:
It could be run off just one of those lipo batteries, but I’d need to make an adaptor and don’t have enough Deans connectors. But since I have four of the lipos…
Well that’s decided the input method for my next project then! :-) Great demo! I’m interested to know whether it’s possible to read the accelerometer values? There’d be some great potential projects if that’s possible.
I haven’t delved very deeply into Cwiid yet, but I have a feeling it’s a complete implementation of the Wiimote comms. Yep, it is. (Checked)
It looks like you can read the accelerometer values and also control the wiimote rumble and leds
Excellent. Onward and upward then ;)
[…] Using a Wii controller with your Raspberry Pi, Gertboard, Bluetooth and Python:”). […]
I have been struggling for a long while to get my PI to detect my logitech wingman joystick in order to control a robotic arm. ( it works with a borrowed joystick of a different make).
so I have purchased the same Bluetooth dongle but bit a problem with the HCITOOL SCAN command in the blog. Nothing works after that.
I will get it cracked, like your demo, I will have to add a gertboard to my shopping list!
Where did you get the switching power unit that supplies power to the Pi?
That’s an ebay job – very cheap, but very good. I’ve got lots of them. Search on “DC-DC StepDown Adjustable Power Supply Module LM2596”. I bought the bare board with reg on and added two USB ports, wires and heatshrink. Quite good because you can tweak the output voltage.
can this be done with an Xbox remote as well?
Good question. I don’t know. Does it run on Bluetooth? Has someone written a Python library for it? If so, YES. It would be very interesting to find out.
[…] ที่มา Raspberry Pi Spy และ Raspi.TV […]
Bought the Tesco Bluetooth dongle, and downloaded and installed all relevant software, but I am afraid I have had a total lack of success with either of my Wii remotes. Thought it may be due my mouse/keyboard and WiFi dongles, so eliminated them and switched to wired Ethernet/USB attachments, but this did not make any difference. The Wii remotes are never detected by the hcitool scan or the python program supplied. The hcitool did locate my panasonic viera television downstairs though!. Also my keyboard entry started to play up in ways I have seen described elsewhere (arbitrary keys being entered eg aaaaaaaaa etc) I dont know if there is a connection. Any ideas of how to recover of have I just wasted a fiver at Tescos?
Well whatever you apt-get install, you can also apt-get uninstall.
I would flash a brand new install of Raspbian on an SD card and follow Matt’s instructions to the letter. So many people have got this working that something must be wrong. The only way you can be sure it’s not your existing setup is to start with a fresh Raspbian install.
It is also possible that your dongle is faulty, I suppose. Tesco has a 1 year guarantee, so you can always take it back. But I’d rather you got it working. :)
Hi Alex, Thanks for the advice. I did have a (very) brief moment of success! but mostly I get the message “Device is not available: No such device” response from hcitool.
To give further background. I was given the Maplin Pi package at Christmas (Pi,USB Keyboard/Mouse, WiFi dongle, 1amp power supply,and a separately powered USB extension, as well as a 4gb Raspbian SD card), I think this is a good value package for starters. I began by using the separate USB extension, which had the WiFi dongle and a remote keyboard/mouse dongle inserted as well as the Bluetooth one. Since I was lacking success, I removed the two other dongles (Wifi,mouse/keyboard), and switched to direct USB mouse/keyboard and wired ethernet, presuming some interference maybe – no improvement, although I did get my downstairs Panasonic TV turning up at one stage! I do have several SD cards with Raspbian installed, so I did follow your advice to try a fresh install of the Wii/Bluetooth software on a different base. I still got the “device is not available” message until!……I moved the Bluetooth dongle off the separate USB extension, and plugged it directly into the Raspbery Pi spare USB slot. Then the hcitool started its scan and did pick up on the Wii remote! I then started up the Python program and it also recognised the Wii remote. I was able to get it to respond correctly to the various Wii remote button presses with the proviso that it never a gave a single keypress response, usually 2 or 3 repetitions. That was the only time I had success. Now after a reboot, I am back with the “Device is not available: no such device” response,
ps Love your YouTube vids, keep them up
I wonder if your dongle is intermittently faulty? I suppose that could be checked on a Windows machine by installing the software that came on the disk and seeing if you can connect to a phone or other BT device. It couldn’t hurt to exchange it at Tescos, but if it doesn’t solve the problem, you’re back at square 1. I’d still recommend an absolutely virgin install of Raspbian and direct connection to the Pi. I don’t even own a USB hub, so I never plug any USB devices in any other way than directly. :)
Hi Alex again, I did check my bluetooth dongle on my Windows system and there were no problems apart from snooty messages from Windows 7 about
its software not being uptodate in its terms. I have now had some more success with the dongle attached to the pi rather than the USB hub, and in fact have returned to using my wireless mouse/keyboard without problems. I did increase the the button_delay to 0.3 secs to avoid multiple keypress problems. It is very strange how some Linux problems seem to self-cure themselves in time; I have never known that sort of behavior in Windows. Also the “stuck keyboard” phenomena as gone away for the moment. That can be immensely frustrating when it occurs; I had at least 25 LXTerminal windows opening themselves in succession because of “stuck” key symptom until I switched power off. Having spent most of a lifetime fighting software and/or system bugs nothing surprises me in this business. Thanks for your advice and interest.
0.3 is exactly what I changed it to as well. :) It seemed like the best compromise.
When I get stuck keyboard issues with my wireless kbd/mouse dongle, I swap out for a different keyboard. It doesn’t happen very often since I don’t use the GUI much and usually log in headless.
The Youtube video isn’t working! :weep:
Thanks. Not working for me either, but my other vids are. I suggest trying again later like it says. Hopefully it’s a technical glitch. That’s my second most popular video, so hope it’s not knackered. :(
It works fine for me on my Nexus 7 in chrome or the Youtube App, but not on my Win7 PC with Firefox. No idea what the issue is. Hope it goes away soon. ;)
[…] Mike Brojak from DesignSpark, whose voice you can hear in the video, asked me to put together a Wii controller flag-waving demo (plus other bits) on their new PiGo board. You may remember catching a glimpse of it in the flag […]
[…] They’ve also recently had a go with the Wii controller Gertboard “Whackadoodle” demo. […]
[…] Gertboard “Whackadoodle” Wii controller […]
The second dongle pictured at the bottom is a wifi dongle, right? Not another Bluetooth one?
That’s correct :)
Possibly a silly question, but wonder if you could give a steer on how you connected up the relay to the Gertboard?
I have got a solenoid / relay circuit working (with a power supply for the solenoid) – however, I am getting a bit stuck on the connections to the Gertboard.
This is all part of a master plan to use a Wii-mote as the controller for a water droplet photo setup!
Any help would be great. BTW have tried the instructions for the bluetooth set-up and it works great!
Thanks!
Are you using a bare relay or have you got a little relay board?
it is a little 5v relay board, like the one in yr video
OK. Blue jumper on the relay board Vcc to Vcc.
Relay board GND to Gertboard GND
Relay board IN1 and IN2 to Gertboard RLY5 & RLY6
Relay board Vcc to Gertboard RPWR
Then connect whatever GPIO ports you want to control your relays with to J4 RLY5/6
Thanks Alex, I will give that a try!
Hi Alex, I saw the original article on Raspberry Pi Spy and want to use the Wii controller to control my robot. I have the sample code working fine, however since I have only recently started using Python I am using Python3, CWiid does not seem to work in Python3, I get an import error “No module named cwiid”
Do you have any idea if cwiid can be used with Python3?
Can’t find any references to it. I learnt Python 2 because I started in 2012 when a lot of stuff wasn’t available for python 3, and the recommended book I bought for my son and me was 2. It’s what all the cool kids used back then. I can see that I’ll need to make the transition at some point, but for the vast majority of stuff I do, 2.7 is still fine.
It seems CWiid has not been in active development for the past four years, so I’ll probably have to revert back to Python 2.7. My code is not complicated so its probably just removing brackets from a few print statements.
You don’t even have to change the print statements if you type…
from __future__ import print_function
near the top of your program
Hi Alex, I just watched a youtube video of your radio controlled car at the April 2013 Oxford Raspberry Jam and noticed you were controlling the car wittha nunchuck. I am successfully using a wiimote with cwiid but I don’t know how to get the nunchuck to work. Could you please point me in the right direction ?
I’ve forgotten exactly how I did it and can’t find the SD card at the moment with the code on.
But this is a pointer in the right direction… | https://raspi.tv/2013/using-a-wii-controller-with-your-raspberry-pi-bluetooth-and-python?replytocom=11514 | CC-MAIN-2019-35 | refinedweb | 2,042 | 71.65 |
need to block ads in my WebBrowser control... How can I do it using actually VB.NET or another program? I have heard about working with hosts file, maybe there any simple adblockers that work for or browsers? --------------Solutions------------- I
NSMutableDictionary* actions = [[NSMutableDictionary alloc] init]; actions[@"run"] = ^ () { NSLog(@"Hello"); }; actions[@"run"](); Xcode reports the error Called object type 'id' is not a function or function pointer when I invoke the block in NSDict
Situation I am trying to tie multiple phone numbers to a client with has_and_belongs_to_many. I am able to add a client and phone number. If I pull up a client where I have three phone numbers, it displays each number, but when I click on edit, it di
Hello I am looking for best way to organize the blocks in a day column when events are in the same or mixed time in Calendar using J2SE. I have for example 3 events in database. I have access to startDate and finishDate and got a function which can g
I am using Flash cc Action script 3. I need it so that when I click on 'Summonblock' a symbol it will summon Block1, I have no idea what the code may be for this. Even after an 1 hour search... Help as it is for a game I am making. Also I need it so
I can't seem to edit the CSS correctly for a block that holds content for the Views Ticker module Here is what I have: #block-views-rotating-news-block{ border:#F00 thin dotted; float:left; left:0%; width:30%; } The content should be IN the block If
I am working on Blocks programming, i have created a block. void(^paint)(void)=^(void){ NSLog(@"Process "); }; now i want to create a nstimer using the NSinvocation and NSMethodSignatiureas below. void(^startPainting)(id)=^(id self){ **SEL selectorTo
Trying to make a website built up by boxes of different sizes. Been mixing a lot with it but can't get this last thing to work. EDIT: So, as you can se in the JSFiddle, the two last boxes are starting on a new row. I want them to be placed between th
Without use of Image processing toolbox to divide the image, I used cell array. If I want to rotate each block I should develope imrotate, but how? working with cell is not easy. Here is my code for division: A= double(imread('cameraman.tif')); block
I have VS 2012 Update 4 installed on my machine (Win7 SP1 x64) and i want to install VS 2013 along side it.The installation blocks and here's the log message: MUX: Stop Block: OlderFLPOnFLPBlocker : The product version that you are trying to set up i
I recently read this post and figured it would be a good idea to use the tips from the article. I'm using it in blocks, but should I also use it in the 'block' below. Is the 'block' below a real block? avatar.frame = ({ CGRect frame = avatar.frame; f
It is as simple as mentioned in the questions I tried it up with another app of mine and tried to unregister its broadcast receiver from my new app but it didn't happened. using th unregisterReceiver(kill2nd);
I am new to using Magento, problem is that I have to create custom email template for different kinds of email formats and these email formats should be editable for user from admin site also I want to send email using these custom email template. So
Suppose I already create a weak self using __weak typeof(self) weakSelf = self; [self doABlockOperation:^{ ... }]; Inside that block, if I nest another block: [weakSelf doAnotherBlockOperation:^{ [weakSelf doSomething]; } will it create a retain cycl
If I have: 2.times do i ||= 1 print "#{i} " i += 1 print "#{i} " end I get 1 2 1 2, whereas I was expecting 1 2 2 3. Why does i lose its assignment when the loop starts over? It behaves as expected if the assignment occurs outside the loop, so I gues
Please let me know what is the definition of Test Suit, Test Module, Test Block, Test Scenario and Test Cases, and what is the relation between them? Thanks, Somnath --------------Solutions------------- There is TONS of information about testing on t
if I have a template in app\design\frontend\base\default\template\dir\template.phtml that look like this <div class='block block-list'> <div class='block-title'><strong><span>Some Block</span></strong></div>
I'm trying to pass a variable using setData to a box containing a widget with this: $this->getChild('my_box')->setData('myvar', '123'); echo $this->getChildHtml('my_box'); or this: echo $this->getChild('my_box')->setData('myvar', '123'
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <unistd.h> #include <fcntl.h> #include <netinet/in.h> #include <arpa/inet.h> #include <sys/types.h> #include <sys/socket.h> int | http://www.dskims.com/tag/block/ | CC-MAIN-2018-22 | refinedweb | 821 | 70.84 |
Code First Migrations
Code First Migrations is the recommended way to evolve your application's database schema if you are using the Code First workflow. Migrations provide a set of tools that allow:
- Create an initial database that works with your EF model
- Generating migrations to keep track of changes you make to your EF model
- Keep your database up to date with those changes
The following walkthrough will provide an overview of Install-Package EntityFramework command
- Add a Model.cs fileDemo { public class BlogContext : DbContext { public DbSet<Blog> Blogs { get; set; } } public class Blog { public int BlogId { get; set; } public string Name { get; set; } } }
- Now that we have a model it’s time to use it to perform data access. Update the Program.cs file with the code shown below.
using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace MigrationsDemo {
- Code First Migrations will compare the migrations in our Migrations folder with the ones that have been applied to the database. It will see that the AddBlogUrl migration needs to be applied, and run it.
The MigrationsDemo.BlogContext database is now updated to include the Url column in the Blogs table.).
- We’re looked at migration operations that don’t change or move any data, now let’s look at something that needs to move some data around. There is no native support for data motion yet, but we can run some arbitrary SQL commands at any point in our script.
- Let’s add a Post.Abstract property to our model. Later, we’re going to pre-populate the Abstract for existing posts using some text from the start of the Content column.
public string Abstract { get; set; }
We'll use the Add-Migration command to let Code First Migrations scaffold its best guess at the migration for us.
- Run the Add-Migration AddPostAbstract command in Package Manager Console.
- The generated migration takes care of the schema changes but we also want to pre-populate the Abstract column using the first 100 characters of content for each post. We can do this by dropping down to SQL and running an UPDATE statement after the column is added. AddBlog command.
Getting a SQL Script -TargetMigration: AddPostAbstract
Submit and view feedback for | https://docs.microsoft.com/en-us/ef/ef6/modeling/code-first/migrations/?redirectedfrom=MSDN | CC-MAIN-2022-27 | refinedweb | 375 | 62.88 |
Max Palmer2,920 Points
arg in args loop not working
For some reason the arg in args loop is not succesfully putting in the arguemnt to the append function.
I looked online and previous lessons but could not see why the arg loop would not be working.
Thanks in advance for help!
# If you need help, look up datetime.datetime.fromtimestamp() # Also, remember that you *will not* know how many timestamps # are coming in. datetimes = [] def timestamp_oldest(*args): for arg in args: datetimes.append(arg) return datetimes datetimes.sort() return datetimes[0]
1 Answer
Steven Parker201,913 Points
Having a 'return" inside the loop will cause the function to end during the first loop pass. It will never get a chance to repeat.
It also prevents any of the later code (like "sort") from being executed.
Max Palmer2,920 Points
Max Palmer2,920 Points
Have since updated the code. For clarity sake see below.
import datetime datetimes = []
def timestamp_oldest(*args): | https://teamtreehouse.com/community/arg-in-args-loop-not-working | CC-MAIN-2020-34 | refinedweb | 160 | 76.82 |
GNU Libc 2.1.3 Released 91
Kaz Kylheku writes, "Ulrich Drepper just posted an announcement to the libc-alpha mailing list that the tarballs are out. This release fixes bugs in diverse areas and improves the stability over last September's glibc-2.1.2 release. The main archive for this is here and it is sure to go out to mirrors like wildfire. Get it, install it, run it---today! "
FM? (Score:1)
Not how new? Why new? Was a.out not good enough? (Score:1)
Re:Efficient? (Score:2)
ann (Score:5)
There you can find the files
glibc-2.1.3.tar.bz2 (also
glibc-2.1.2-2.1.3.diff.gz
glibc-linuxthreads-2.1.3.tar.gz
There is no new crypt add-on since it hasn't changed.
This release fixes many bugs in all parts of the library and everybody
is encouraged to update. Preferably through your distribution
provider since compiling glibc yourself means taking a risk unless you
know exactly what you are doing.
This release should be fully compatible (both directions) with glibc
2.1.2. The only part which changed is the format of the files
containing the locale data. This can be easily fixed by running the
`localedef' program for the locales which get used on the system (or
by running `make localedata/install-locales' to update all of them).
--
---------------. drepper at gnu.org
Ulrich Drepper \
Red Hat `--' drepper at redhat.com `------------------------
Re:Updates... (Score:1)
New != better.
I am happy that the crypt() code needed no changes - this indicates that it is stable. Stable crypto code = good.
Alternative lib C (Score:2)
Cross platform (Score:2)
It implements many standards, apart from ANSI/ISO C also various Posix and Open Group standards.
It will never be completely debugged, since both the standards and the underlying OS'es keep changing.
It is written in GNU C.
It's effect on performance depends on what you do. It can range from "none" to the only significant factor, depending on how much your application uses library functions.
Re:Feed Me Signal (Score:3)
The GNU Libc does support operating systems other than Linux; it is compilable across multiple architectures.
There is a lot of stuff other than standard C that is implemented; a library for a UNIX-like system must implement the POSIX interfaces as well as The Single UNIX Specification.
A C library is typically written using the C language, but with platform-specific extensions and tricks. Obviously, the system call mechanism that is used to interface with the system can't be written in C. Certain assumptions about the hardware are made here and there. (Consider implementing stuff like , or printf conversions, etc).
C libraries are not fully debugged after years of development because they are large, and the standards are moving targets. In the case of glibc, it's actually not that old. From what I understand, glibc2 is a rewrite of glibc1.
I suspect that proprietary libc's are more stable because they have been around longer. But they acquire new bugs when they implement new UNIX features.
The quality of a library implementation is critical to system stability, and in some cases performance as well. Obviously, those library funtions that are basically thin wrappers around operating system calls don't impact performance much. On the other hand, there are areas where optimizations can make a huge difference: things that come to mind are DNS resolver functions, the stuff in .
Updates... (Score:5)
I understand that the priority needs to be a stable C library, and that the other stuff is really so much frippery, when you get right down to it. On the other hand, I would find it almost impossible to imagine two fairly significant bits of code requiring -NO- updates or touches for such a large leap in versions.
I've not plowed through the entire 2.1.3 sources to see how much of this old code they've simply rolled in, but I don't see any READMEs or notices in the glibc directory declaring the files as obsolete, either.
This is NOT a complaint. Ok, well, maybe it is. I simply think it'd be nice if related software could be kept in sync, with either versioning or notices stating that.
PS: Last distro to upgrade is a rotten LinuxOne!
It's 1999 all over again.. (Debian complainer :) ) (Score:3)
Luckily, the package-pools stuff will supposedly get this stuff into a 'semi-stable' distribution posthaste, although I'd be a little nervous about throwing a new libc in. [1]
Daniel
[1] OTOH,
Re:Crypto still separate (Score:1)
To the best of my knowledge, no. I believe that the source code export restrictions have not been removed. Binaries only. Good for M$, good for NS/AOL, not good for us.
Re:It's 1999 all over again.. (Debian complainer : (Score:1)
Re:It's 1999 all over again.. (Debian complainer : (Score:1)
I have found that Netscape works much better with this libc than 2.1.2. No mysterious crashes when closing Netscape windows.
Oh boy, cygnus slashdotted ! (Score:1)
Have you tried to get the tarballs today?
Good luck.
The dang place has been overwhelmed !
Oh boy !!
Re:Updates... (Score:2)
Re:Oh boy, cygnus slashdotted ! (Score:1)
I've just downloaded the 3 files.
Re:Updates... (Score:4)
Efficient? (Score:4)
However, all of that massive feature-set support and backwards compatibility and cross-kernel compatibility incurs a cost; doing a stat() is no longer just a system call, but instead has to pass through a layer of glibc code to convert whatever the kernel's struct stat du jour is to the glibc "standard" format. And symbol versioning, while extremely useful, adds complexity and latency to the start-up of processes which link against glibc (i.e. EVERYONE).
Linus has commented a few timees that glibc is a little too heavyweight for his tastes; others have noted that, while the Linux kernel's fork() rate and latency are incredible, it's the ld.so complexity and latency that kills us on exec()s.
I have often pondered a project to parallel glibc, called "tlibc" - the Thin C Library. This library would have to be compiled against the kernel it expects to run against; what's more, apps would then have to be compiled against the newly compiled tlibc, because it only guarantees source-compatibility (and that only so long as kernel interface structures don't change in fascinating and difficult-to-handle ways).
Sure, it would be a PITA to develop such a system, but imagine it in the context of a distribution... let the applications come as close to the "raw iron" of the kernel as possible to eek that extra 3% performance out of Apache/Samba/etc. Remember, most production systems pick a distribution and stick with it, WITHOUT DOING ANY NON-SECURITY UPGRADES, for a long time. This could actually be plausible.
Then again, maybe it's just pipe dream. I dunno.
Re:ann (Score:1)
Such a disgrace....
:)
Finkployd
New Fangled Wussie! (Score:1)
LK
Clarification (Score:1)
When I refer to October GNOME, I mean that Red Hat should have waited for that release. I don't mean that October GNOME is unfit for production use.
Re:***WARNING*** Upgrade with caution! (Score:2)
The problem is, upgrading a Red Hat 5.x box to glibc 2.1 (now standard in Slack 7) is impractical, because of the soname issue. (libc.so.6 vs. libc.so.6). If Red Hat had heeded the glibc unstable warning, in the same way they heed the kernel unstable warnings (2.2.x vs 2.3.x), I'd be happy.
You see, since Slackware stuck with libc.so.5, upgrading to glibc 2.1 is relatively painless (the transition can be made gradually, first with new apps, then recompiling/reinstalling the older stuff), because the sonames are different.
Glibc developers aren't to blame, because they left the soname the same, while breaking binary compatibility. You weren't supposed to be using the unstable library in a production box, anyway. Red Hat just got too "cool" and jumped the gun, in the same way they loaded on GNOME far before it was really ready for use (October GNOME).
This reminds me of the inflammatory emails linux-kernel gets, when people whine that some internal structure changed, and that linux will never be "professionally trusted" if they keep breaking things.
Re:***WARNING*** Upgrade with caution! (Score:4)
It's not their fault, like you make it out to be, that distributions like Redhat included glibc 2.0, only to find out that glibc 2.1 broke binary compatibility.
Stick with Slackware if you want to avoid that sort of problem. Everyone snickered at Slackware, saying "it's so backward" because it didn't "upgrade" to the new, unstable library...
Now the glibc 2.1 series is out, marked "stable", Slackware is fine, and the Red Hat 5.x boxes are having problems with libc.so.6 (from glibc 2.0) not working like libc.so.6 (from glibc.2.1). Who's snickering now?
Re:Go ahead (Score:1)
How about adding another section (to accompany apache, askslashdot, etc - maybe called "releases") so that people can filter the stories out a bit easier.
Just my 2 cents.....
Re:Go ahead - Brilliant idea (Score:1)
Create a section for semi important software releases on
And, by all means post really important SW releases on the main page.
Re:Go ahead - Brilliant idea (Score:1)
As much as I loathe M$, Why2k is rather relevant but Gadget 4.0.3pre42.alpha is not....
Re:How new? (Score:2)
Please set your system clock to todays date. We can not allow people to download tomorrows software today
Seriously, it seems as if there is a version numbering problem....
Re:FM? (Score:2)
AC is suggesting in two words that this whole article belongs to freshmeat.org.
I do actually agree! I want to see XFree86 4.0 and other major releases on
The "troll" moderation is grossly unfair and I would like to point people that do moderation to sid=moderation [slashdot.org]
Crypto still separate (Score:1)
It just seems that it makes life easier for almost everyone if they're one package. (Imagine if the Linux kernel was distributed separately from all the device drivers...)
Re:Not how new? Why new? Was a.out not good enough (Score:2)
all your foo.so files are ELF, as are the executables that use them
.a files IIRC are pre-compiled statically linkable binaries, in a.out format
We are all in the gutter, but some of us are looking at the stars --Oscar Wilde
Re:Go ahead -- good idea (Score:1)
How new? (Score:3)
glibc-devel-2.1.3-6
compat-glibc-5.2-2.0.7.1
libc-5.3.12-31
quake2-3.20-glibc-6
glibc-2.1.3-6
And I haven't even downloaded anything today!
Re:***WARNING*** Upgrade with caution! (Score:1)
Being cutting-edge is intrinsically good; if you can't put up with the occasional bug and fix coming rapidly along, go back to another OS, thou evil troll!
Re:***WARNING*** Upgrade with caution! (Score:1)
Yup, that's always possible.
I'm hardly a RedHat fan, for all I disagreed with the "slackware v RedHat" in the original comment.
"...linux will never be "professionally trusted"..."
Eeek, that argument is so bogus it's unbelievable. "Professionals" either aren't being professional, or are just being lusers if they can't cope with the occasional fix.
Me, the way I operate is at the cutting edge of Debian "unstable" - not "potato" or "frozen", the real unstable thing. I apt-get dist-upgrade every day as a matter of course; and I have to wangle things to get packages to install, such as hacking
Re:Feed Me Signal (Score:2)
The GNU C library (version 2) only supports Linux and Hurd as kernels, as far as I know. Some README file somewhere says that porting it to other OSes should be an easy task, but it looks like it hasn't been done.
Congratulations (Score:5)
to the GNU libc team.
Writing a libc is a horribly fastidious job. Perhaps not as technically hard as writing a C compiler like gcc, but probably far more tedious. Making everything reentrant, maintaining nitty-gritty compatibility with the standards, trying hard not to break everything with each release, this is a very hard job. Remember, for one thing that the headers must compile with gcc -O6 -Wall -ansi -pedantic -W -Wstrict-prototypes -Wcast-qual -Wpointer-arith -Wwrite-strings and this isn't really obvious. Also consider the important aspect of namespace pollution which must be avoided at all costs.
The GNU libc is a fantastic thing. It beats the hell out of the old libc5, which I found mostly worthless. It does a wonderful job of respecting the standards (just look at the features.h header file for an idea) while at the same time providing its own features when they seem useful. And it is very efficient. The documentation is very good, also (very complete, while at the same time very readable; and lots of examples too), even though I detest this texinfo format.
Also remember that a good part of the GNU Hurd is actually in the libc, since it takes care of communicating with the daemons of the Hurd and providing the interfaces (representing depth) that simulate Unix behavior.
ELF symbol versioning is another great thing that was introduced with version 2.1 of the libc. Not to mention things like IPv6 support and so on. In fact, I find that the libc is definitely ahead of the kernel (consider the case of the getcontext() function, which the libc has support for, but tthe kernel is still lacking.
The GNU libc plays an essential role in making our OS what it is. It gets far less attention than the kernel (because of its “cathedral” development model), but it is just as important (remember: a well-written program never sees the kernel, it only sees the libc; the libc is what keeps Unix united, and it can even achieve binary compatibility), and the GNU libc programmers certainly deserve praise for what they are writing.
So, congratulations to Andreas Jaeger, Ulrich Drepper and all the others.
Re:Bugs... (Score:1)
for versions of glibc -prior- to 2.x (I think it
may be broken in 2.0 as well, but I don't recall what the results of the testing were), the aforementioned behaviour didn't exist.
This -has- been verified by using different glibc versions on the same machine, and using different glibc and C library versions on different operating systems (AIX, FreeBSD, NetBSD and Linux were the OS's used for testing this behaviour).
Bugs... (Score:2)
fork() is/was broken in 2.1.0, 2.1.1 and 2.1.2 for the specific app that it's being used for, and the manner that it's being used is consistent with how it's supposed to work (IIRC).
*shrug*
basically: in the case where an app forks off a child process, then returns, and then has another child process fork()'d (each process running the same external app), is it still freezing/not returning from the child cleanly?
That seems to be the bahaviour, at any rate...
(source code for the app can be provided for testing of this behaviour).
I like software announcements on Slashdot! (OT) (Score:1)
I know all about Freshmeat, and I read it regularly, but it's full of software that just doesn't interest me. Today I've had to sift through a program to flash Morse code on the keyboard LEDs, a window manager that describes itself as "pointless", and a whole lot of programs for manipulating my non existent MP3 collection in previously unimagined ways. I don't mean to bash these programs in particular. I'm sure they're good at what they do, and that the authors have put a lot of hard work into them. I'm afraid they just don't interest me.
The software that appears on Slashdot is the really important stuff (IMO): Linux kernels, C libraries, X servers, etc. I like to hear about it on Slashdot. When we start seeing "Yet another HTML preprocessor 1.2.1.1" on the front page I'll complain as loud as everyone else, but until then I'll be happy.
Perhaps the real problem is with Freshmeat?
Love
Molly
Go ahead (Score:1)
I'm not complaining that this was posted on Slashdot. Slashdot can post whatever they'd like. But it doesn't belong under the GNU heading. It, along with all the development kernel releases, and the new versions of XFree86 need to have their own section. I, like a great many people here, read Freshmeat precisely for this sort of thing. I understand that some things deserve to be posted here on
/., and all I'm asking for is the ability to filter them out.
-----------
"You can't shake the Devil's hand and say you're only kidding."
Re:Go ahead (Score:1)
It's like saying "Yes, I know you want to moderate me down. Do it, and then go fuck yourself". Maybe a little unneccesary, but it irks me to know ahead of time what a moderator is going to do, based on the subject of my post.
-----------
"You can't shake the Devil's hand and say you're only kidding."
Re:FM Posters.. (Score:2)
-----------
"You can't shake the Devil's hand and say you're only kidding."
Re:FM Posters.. (Score:2)
The reason I argued the point, was because there's an obvious trend on Slashdot now for posting software releases. I think those releases *deserve* their own section, in the same sense that BSD and Apache do. I'd like to be able to create a slashbox for new releases, so I can go discuss them. They have a place on Slashdot, but I don't think it's mixed in with all the other stuff.
-----------
"You can't shake the Devil's hand and say you're only kidding."
Moderation :) (Score:3)
It's sad that ANY comment could conceivably fit each category
-----------
"You can't shake the Devil's hand and say you're only kidding."
Re:So what makes a "major release" (Score:2)
I fully agree with what you think are major releases, and I also don't really think that the Stampede code freeze qual'd as 'major'... once it is actually released, maybe... Like "1.0 released today", rather than ".90 coming Any Week Now(TM)"... Considering that you *need* a c lib to build Linux, I'd consider this pretty major... anything that you *need* to run (some people don't need X, but..) Linux/BSD/Foonix/BarSD 8^) Not like "I *need* pine, and version umdiddlysquat.whoosymawhatchis.whatchmacallit is out - YAY!", but legit components of the system.
My point was that even a 'minor' version increment for glibc is rather *major*... the previous updates were:
2.0.6 12/29/97
2.1.1 5/25/99
2.1.2 9/7/99
2.1.3 2/25/00
Not really an everyday sort of thing... I think it deserves a post here. That's all.
Minor is tougher to define, but I think it's safe to say that it is anything that isn't 'major' 8^D
Or whatever...
So here's the gist of it... (Score:3)
2) People complaining about those people, saying that 99% of the stuff on Freshmeat doesn't apply to them, but major releases like libc, XFree, Kernels, do, so keep listing it here...
3) People complaining about troll moderation for #1
4) More complaining that we should have a new section for these sorts of things...
5) People complaining that this isn't new...
6) People complaining about all of the complaints 8^)
and soon...
7) People complaining about me 8^)
I maintain that kernel releases, major X announcements, and other key components (GCC, Glibc, etc) should be announced on
Major announcements should be done on
Even though this is a x.x.1 increase, it *has* been quite some time, and *is* a fairly major step. If every day we got the libc-digest posted here, I'd start to worry, but if the last update was in September, and this interval is too often for you to handle it... (you're creative enough to figure out what I was thinking here, I'll bet)
OH, NO!! (Score:1)
My, does 2.1.3 also build itself "recursively" on 'make install' like 2.1.2?
glibc manual online? (Score:1)
Moderate this up was: Re:libc? Who cares? (Score:1)
Regarding FM complaints (Score:2)
Chris Hagar
Re:Go ahead (Score:5)
Note however, that if I still had my moderator status, I would have moderated you right down to 0 from 1 where you are already. I very much agree with the other
JD
Re:How new? (Score:1)
<TT>
[billk@cr957697-a billk]$ su root
[root@cr957697-a billk]# rpm -ivh glibc-2.1.3-6.src.rpm
glibc #################################################
[root@cr957697-a billk]# exit
exit
[billk@cr957697-a billk]$ diff glibc-2.1.3.tar.gz
Binary files glibc-2.1.3.tar.gz and
[billk@cr957697-a billk]$ ll !*
ll glibc-2.1.3.tar.gz
-rw-rw-r-- 1 root root 8277967 Jan 31 09:32
-rw-r--r-- 1 billk users 9013927 Feb 25 06:44 glibc-2.1.3.tar.gz
[billk@cr957697-a billk]$
</TT>
Re:Not how new? Why new? Was a.out not good enough (Score:1)
ELF is not GNU, lots of Unices (Like Solaris) have been using it for years. Mainly because only an idiot would attemt to create shared librarys with a.out.
TeX is not GNU, it was written by Donald Knuth. Never used troff, but I hear it was bad in comparison.
Re:Go ahead (Score:1)
If you are jealous that your posts are not as insigitful as the ones you are reading, fine - think some more before you post. If you feel disgusted about the tone in which people speak, too bad - just don't assume what goes on inside the poster's mind (e.g. "hm...I want to be a martyr") when you reply. It seems very immature to me.
Sorry I just can't help posting the rant. I've seen far too many "I'll give you what you ask for" posts regarding this matter. You should note that the person is merely anticipating - whether or not they're asking for a demoderation is totally up to your imagination.
Re:How new? (Score:3)
Re:How new? (Score:2)
For betas, it's not uncommon (or bad) to ship pre-release code.
Re:Is this a major release? (Score:1)
hope its just me! (Score:1)
***WARNING*** Upgrade with caution! (Score:4)
The issue is that almost all programs on your system depend on glibc. This is about the only library about which such is true. Also the glibc people are infamous for binary (and hell, source too) incompatibility...even between minor versions. In addition it sounds like most of the gains are stability. If you end up screwing your system over...you haven't increased stability much, eh?
Just watch out
-nullity-
I am nothing.
libc? Who cares? (Score:1)
Real Men bypass libc and use straight system calls to interface with the kernel. Ha! And none of this weeny C crap either. Everything handcoded in assembly... I remember the days when we wrote our first assembler in straight binary. Nah, forget that, I remember PUNCH CARDS! And running programs in your head because it took two days to pass through the machine!
libc
don't make me laugh....
Feed Me Signal (Score:2)
Honest questions.
Re:FM Posters.. (Score:1)
So I will make this as a suggestion.
Skip over the articles. It doesnt hurt to see GNU Libc x.y.z is out and just not read it does it? I mean if it does I will complain for you
If there was a filter for *everything* people wanted hemos and taco would spend all day coding filters! use your brain it filters excellent.. I got so good I could totally ignore my wife
Re:FM Posters.. (Score:1)
FM Posters.. (Score:3)
/. has been posting software upgrades like this for all eternity. I mean they dont report things like Frog0.0.1 First Release
I happen to enjoy reading about what others have to say on the software that is "important" to the community. glibc IS important
Ive learned a WHOLE lot by what other people have said here at
Please do not go bashing saying this belongs at FM
Been reading
So what makes a "major release" (Score:1)
I agree with that major releases should be announced on
For major releases I would think something in the lines of XFree4.0, FreeBSD4.0, Linux2.4 and not all those nightly CVS-builds....
But I may be wrong, so would someone please explain to me what "major" includes and the difference between major and minor. Right now I don't see any.
Bjarne
Re:ann...crypt add-on (Score:1)
Re:ann...crypt add-on
(Score:-2)
by NRLax27 on 7:56 25 February 2000 PST
(User Info)
If you follow the link in the glibc-crypt.readme on, it brings you to a site that has a 2.1.3 version of the libcrypt addon. Did they just change the version number to match, or is there really a new version?
END:cut-and-paste
I don't like the fact that some people now seem to have a default score of -2.
Re:Updates... (Score:3)
The lastest crypto patch isn't the one on cygnus' ftp site. The latest one is 2.1.2, which you can find on, among other places (search). The announcement says crypto patches didn't need updating, so you can use the 2.1.2 crypto patches for glibc-2.1.3
The locale info is now distributed as part of glibc, so it's in the gblic-2.1.3 tarball.
You see, all glibc-packages *are* up-to-date. And, imho the glibc guys are doing a great job. Glibc is as important and complicated as the Linux kernel. Glibc guys aren't as well known as linux guys though.
The only problem is that the ftp directory listing is admittedly somewhat confusing. Worse, the ftp site is rather confusing and it holds imho too much outdated tarballs. If someone would clean up that ftp site a bit, it would save quite some bandwidth and diskspace for mirrors.
Regards,
Maarten
Re:Bugs... (Score:1)
Re:ann (Score:1)
5d28eb5376031c4cf7ba6057322852fd glibc-crypt-2.1.tar.gz
There have been no changes to glibc-crypt since the 2.1 release. | https://slashdot.org/story/00/02/25/089241/gnu-libc-213-released | CC-MAIN-2017-04 | refinedweb | 4,558 | 74.59 |
Computer Science Archive: Questions from April 07, 2008
- Anonymous askedI am writing this program for java, but I would like to havereference to another incase I need help.... Show more
I am writing this program for java, but I would like to havereference to another incase I need help. Thanks for the help!
Details
To approximate the square root of a positive number n usingNewton's method, you need to make an initial guess at the root andthen refine this guess until it is "close enough." Your firstinitial approximation should be root = 1;. Asequence of approximations is generated by computing theaverage of root and n/root.
Use the constant:
private static final double EPSILON = .00001;
Your loop for findSquareRoot should behave likethis:
make the initial guess for root
while ( EPSILON < absolute value of the differencebetween root squared and n )
calculate a new root
return root
Your class should have a constructor that takes the number youwant to find the square root of. Implement the usual accessormethod(s) and a findSquareRoot method that uses Newton'smethod described above to find and return the square root of thenumber. Add a method setNumber that takes a newnumber that replaces the number in the instance field. Supplya toString method that returns a string containing thenumber and the square root of the number.
Your test class should:3 answers
- Anonymous asked2 answers
- Anonymous asked3 answers
- Anonymous asked2 answers
- Anonymous askedWe have been usingPowerPC eieio(Enforce-In-Order Execution of I/O) assembly languageinstruction... Show more
Hi,We have been usingPowerPC eieio(Enforce-In-Order Execution of I/O) assembly languageinstruction on Freescale MPC500 Family Microcontrollers.
Can we use this instruction on Freescale MPC5500 FamilyMicrocontrollers, for example MPC5566? If yes, do we need tomodify any registers to make this instructionwork?
thanks.• Show less1 answer
- Praggy asked1 answer
- Anonymous asked1. What is theoutput of t... Show more
vector<int> v(10, 5);
v.push_back(7);
cout <<v.front() << " " << v.back();
1. What is theoutput of the code fragment above?
a. 5, 7
b. 5, 10
c. 7, 5d. 7, 10
vector<int> v;
v.push_back (3);
cout << v[0];
2. What is the output of the codeabove?
a. 0
b. 1
c. 2d. 3
vector<int> v (1,1);
v.push_back (2);v.push_back (3); v.push_back (4);
vector<int>::iterator i =v.begin();
vector<int>::iterator j = i + 2; cout<< *j << " ";
i += 3; cout<< *i << " ";
j = i - 1; cout<< *j << " ";
j -=2;
cout << *j<< " ";
cout <<v[1] << endl; //output 1
(j < i) ?cout << "j < i" : cout << "not (j < i)"; cout<< endl; // output 2
(j > i) ?cout << "j > i" : cout << "not (j > i)"; cout<< endl; //output 3
i =j;
i <= j&& j <= i ? cout << "i and j equal" : cout<< "i and j not equal"; cout
<< endl;//output 4
j =v.begin();
i =v.end();
cout <<"iterator distance end - begin =^ size: " << (i - j);//output 5
3. What is theoutput at the line labeled output 3?
a. j >i
b. not(j >i)
c. j <i
d. not(j <i)1 answer
- Anonymous askedeach object of the class bookType can hold the followinginformation about a book:title,up to fouraut... Show more
each object of the class bookType can hold the followinginformation about a book:title,up to fourauthors,publisher,ISBN,price,and number of copies in stock.To keeptrack of the number of authors,add another member variable• Show less1 answer
- Anonymous askedfind an optimal parenthesization of a matrix-chain product whose sequence of dimensions is <10,20... More »1 answer
- Anonymous asked0 answers
- Anonymous askeddraw the recursion tree for the MERGE-SORT procedure fromsection 2.3.1 on an array of 16 elements.Ex... Show more
draw the recursion tree for the MERGE-SORT procedure fromsection 2.3.1 on an array of 16 elements.Explain why mwmorizationis ineffective in speeding up a good divide-and-conquer algorithmsuch as MERGE-SORT.• Show less1 answer
- Anonymous asked1.The time complexityof the function isEmpty in an array list is O(1). a. True b. False 2. Every obj2 answers
- Anonymous asked1 answer
- timeiz2short askedThis program is suppose to ask theuser to enter the amount of a purchase. Then it computes thecount... Show moreThis program is suppose to ask theuser to enter the amount of a purchase. Then it computes thecounty tax and the state tax and then the total tax as well astotal sale. So why it won't run I have no idea but thisproject is long overdue and if there is anyone that can help me Iwould really appreciate because I really want to understand how towork with this to keep up with my class which is hard enough sinceI can't hear. So please look at the program below and tell mewhat's wrong it.import java.util.Scanner;• Show less
/**
Sales Tax Program
This program will ask the user to enter a purchase amount atwhich time the
amount of purchase plus the total sales tax will be computedwhich includes
the state sales tax and the county sales tax. Alsothese results willl be
displayed as well as the total computed.
*/
public class SalesTax
{
// Still don't know what this line is reallyfor.
public static void main(String[] args)
{
// Will compute the amount for state tax
double stateTax;
//Will compute the amount for county tax
double countyTax;
// Will compute the amount of total tax
double totalTax;
double amount;
// Will compute the total sale
double totalSale ;
double purchase;
Scanner keyboard = new Scanner(System.in);
countyTax = 0.02;
stateTax = 0.04;
System.out.print("Enter the amount of yourpurchase");
purchase = keyboard.nextDouble();
totalTax = purchase * stateTax + purchase *countyTax;
totalSale = purchase + totalTax;
System.out.print(purchase * stateTax);
amount = keyboard.nextDouble();
System.out.print(purchase * countyTax);
amount = keyboard.nextDouble();
System.out.print(purchase * stateTax + purchase* countyTax);
totalTax = keyboard.nextDouble();
System.out.print(totalSale);
}
}6 answers
- Anonymous askedHi, I need help writing a program. I 'm not a computer major,but I have to take this class for gradu... Show moreHi, I need help writing a program. I 'm not a computer major,but I have to take this class for graduating requirements. Ihave never done programming in my life and this is my firstprogram assignment and I was wondering if someone can help me startit and give me adivce on how to continue it or end it.Problem: Transported back in time (with your computer) you arein charge of harbor defenses for your city. Using the recentlydevelped length standard, the meter, the cannon master wants to nowif a shot fired at a given velocity from his cliff-mountedcannon will hit an enemy ship entering the harbor. In addition tothe velocity, he gives you the height of the cliff, the distancefrom the ship, and the width of the ship. You decide to amaze thegeneral by develping a program to solve the problem.You can assume that the cannon is mounted horizontally. theship distance is given from the end of the cannon to the middle ofthe ship.Picture:to make the problem easier, this is what I did and what myteacher also prefers:To determine the distance of the shot you must dermine howlong it takes the cannon ball to fall from the height of the cliff.the initial downward velocity is zero. Use 9.8 m/s to representgravity.Note: I also have to make note of the units when Iwrite my program, when i plug in numbers, i have to come out withsomething meters. I also need help with that.The equation my teacher provided us is with is:then, the distane of the shot=velocity*timeSome specification of the program is that all numericaloutputs should be done using %f flag, the all calculations shouldmaintain as much precision as is supported by the C double type inthe gcc compiler. Assume all inputs will be greater thanzero.This is how I started mine:/* calculate the distance of the cannon ball */#include <stdio.h>#define GRAVITY 9.8int main(void){double height >0double width > 0double velocity>0doubleit right?2) on my paper, my teacher gave us an example of asample run:enter the height of the cliff (meters):50enter the distance of the ship from the cliff(meters):180Enter the width of the ship(meters):15Enter the velocity of he cannon ball(meters/second):Distance of ball: 175.691055metersDirect hit!!!!!!So after i write my program, i'm guessing my screenwill haveenter the...enter the...enter the...then the teacher plugs in numbers and solves theproblemsBut on the formula given, it doesn't include all widthof the ship. should i put all this variable like the width in myprogram still?When my teacher tests each program: he's going to havea set of numbers and he going to type in this number and pressenter and it's going to tell him the distance.so how would i do this. please help. I don't want tofail this class.• Show less5 answers
- Anonymous askedWrite a program that declares three one-dimensional arrays namedprice, quantity and amount. Each arr... Show moreWrite a program that declares three one-dimensional arrays namedprice, quantity and amount. Each array should be declared inmain(). and should be capable of holding 10 double-precisionnumbers. The numbers that should be stored in price are 10.62,14.89, 13.21, 16.55, 18.62, 9.47, 6.58, 18.32, 12.15, 3.98. Thenumbers that should be stored in quantity are 4, 8.5, 6, 8.35, 9,15.3, 3, 5.4, 2.9, 4.8. Your program should pass these arrays to afunction called extend (), which should calculate the elemnts inthe amount array as the product of the equivalent element in theprice and quantity arrays.
After extend has put values into the amount array, the values inthe array should be displayed from within main.
• Show less1 answer
- Anonymous askedcha... Show more
Consider thefollowing lines of code:struct studentType
{char name[27];double gpa;int sID;char grade;};int *p;double *q;char *chPtr;studentType *stdPtr;1. The statement“p++” increments the value of p by ____ bytes
a. 1
b. 2
c.4
d. 8
2. The statement“stdPtr++” increments the value of stdPtr by____
bytes.
a. 10
b. 20
c.40d. 80I answered C for both. is thatcorrect?• Show less1 answer
- Anonymous asked1 answer
- Anonymous askedWrite a Program to test the various opera... Show morePlease assist me with this program. This is my 2ndattempt.Write a Program to test the various operations of the classclockType.Thank you• Show less1 answer
- Anonymous askedIn Java a final class must be sub-cl... Show moreAccording to java conventions Please Help me solving theseMCQs.
In Java a final class must be sub-classed before it.
?? True
?? False
A top level class without any modifier is accessible to
?? any class
?? any class within the same package
?? any class within the same file
?? any subclass of this class
A top level class may have only the following accessmodifier.
?? Package
?? Private
?? Protected
?? Public
In Java an abstract class cannot be sub-classed
?? True
?? False
Given a one dimensional array arr, what is the correct way ofgetting the number of elements in arr
?? arr.length
?? arr.length – 1
?? arr.size – 1
?? arr.length()
When recursive method is called to solve a problem, the methodactually is capable of solving
only the simpler case(s), or base case(s).
?? True
?? False
Which of these are valid declarations for the main method?
?? public void main();
?? public static void main(String args[]);
?? static public void main(String);
?? public static int main(String args[]);
Map interface is derived from the Collection interface.
?? True
?? False
In Java, which of these classes implement the LayoutManagerinterface?
?? RowLayout
?? ColumnLayout
?? GridBagLayout
?? FlowLayoutManager
BorderLayout is the default layout manager for a JFrame’scontent pane
?? True
?? False• Show less2 answers
- Anonymous askedCode the base class Member. Your class must include accessor/mutator properties or metho... Show morex.Code the base class Member. Your class must include accessor/mutator properties or methods for each state variable and at least one constructor. The virtual method Exercise( ) will calculate and return a double representing the pounds lost by the member based on the following formula:
poundsLost = (minutesOfExercise*0.03024*currentWeight)/3500
Code the derived class Hiker. Your class must include an accessor/mutator property for the additional data member and at least one constructor. It must contain a polymorphic implementation of the Exercise() method using the following formula:
poundsLost = (minutesOfExercise*0.03024*currentWeight)/3500
Code a Main method to test the methods defined in the Member and Hiker classes. Specifically, at least one object MUST be instantiated from each class. Use the objects to test the method Exercise() in both classes. Note: you do not need to test the functionality of the other components in your classes.9Ïmx.õ..õx.øi5 • Show lessHere is what I have so far. I am having a few issues when I debug
using System;
using System.Collections.Generic;
using System.Text;
namespace Lab6
{
class Member
{
protected double currentweight;
public Member() { }
public double currentWeight
{
get { return currentweight; }
set { currentweight = value; }
}
public virtual void Exercise(double a)
{
if (a <= currentweight)
{
currentweight -= a;
Console.WriteLine("Here is your current weight!");
}
else
Console.WriteLine("No weight entered!");
}
class Hiker : Member
{
public Hiker() { }
public virtual double GetPoundsLost(double minutesOfExercise)
{
double poundsLost = (minutesOfExercise * 3.024) / 3500;
return poundsLost;
}
}
class Test
{
static void Main(string[] args)
{
Member myMember = new Member();
myMember.currentWeight = 170;
myMember.minutesOfExercise = 60;
Console.WriteLine();
Hiker myHiker = new Hiker();
myHiker = (minutesOfExercise * 0.03024 * currentWeight) / 3500;
Console.ReadLine();
}
}
}
}0 answers
- Anonymous asked1 answer
- Anonymous asked0 answers | http://www.chegg.com/homework-help/questions-and-answers/computer-science-archive-2008-april-07 | CC-MAIN-2014-35 | refinedweb | 2,245 | 58.18 |
In Google Maps API v2, if I wanted to remove all the map markers, I could simply do:
map.clearOverlays();
How do I do this in Google Maps API v3?
Looking at the Reference API, it’s unclear to me.
6
Same problem. This code doesn’t work anymore.
I’ve corrected it, change clearMarkers method this way:
set_map(null) —> setMap(null)
google.maps.Map.prototype.clearMarkers = function() { for(var i=0; i < this.markers.length; i++){ this.markers[i].setMap(null); } this.markers = new Array(); };
Documentation has been updated to include details on the topic:
5
- 1
- 4
But does this clear the markers from memory? I realize JavaScript has automatic garbage collection, but how do we know Google’s API does not hold a reference to the marker when setMap(null) is called? In my application, I add and “delete” a ton of markers, and I would hate for all those “deleted” markers to be sucking up memory.
Jul 23, 2010 at 4:11
- 4
This question is answered in the documentation now. code.google.com/apis/maps/documentation/javascript/…
Jan 20, 2011 at 19:43
- 1
It seems that there is no such function in V3 yet.
People suggest to keep references to all markers you have on the map in an array. And then when you want to delete em all, just loop trough the array and call .setMap(null) method on each of the references.
See this question for more info/code.
My version:
google.maps.Map.prototype.markers = new Array(); google.maps.Map.prototype.getMarkers = function() { return this.markers }; google.maps.Map.prototype.clearMarkers = function() { for(var i=0; i<this.markers.length; i++){ this.markers[i].setMap(null); } this.markers = new Array(); }; google.maps.Marker.prototype._setMap = google.maps.Marker.prototype.setMap; google.maps.Marker.prototype.setMap = function(map) { if (map) { map.markers[map.markers.length] = this; } this._setMap(map); }
The code is edited version of this code I removed the need to call addMarker manually.
Pros
- Doing this way you keep the code compact and in one place (doesn’t pollute the namespace).
- You don’t have to keep track of the markers yourself anymore you can always find all the markers on the map by calling map.getMarkers()
Cons
- Using prototypes and wrappers like I did now makes my code dependent on Google code, if they make a mayor change in their source this will break.
- If you don’t understand it then you won’t be able to fix it if does break. The chances are low that they’re going to change anything which will break this, but still..
- If you remove one marker manually, it’s reference will still be in markers array. (You could edit my setMap method to fix it, but at the cost of looping trough markers array and removing the reference)
5
- 1
Meh sorry for delay, I was holding back from posting code because I had no way to quickly test it.
Oct 9, 2009 at 17:43
- 1
I tried using setMap(null), but I had an auto-updating script, and every time I set all 50 or so of my markers to a null map, I still had a bunch of mapless markers floating around in the DOM somewhere. This kept causing the page to crash because each 30 seconds it added 50 new markers to the DOM, and this propagated endlessly because the page stayed open 24/7 on a video wall. I had to use the top answer and clear all map overlays from the DOM entirely before creating new ones. Hope this helps someone; it took a long time for me to figure out why my page was crashing! 🙁
Jul 25, 2012 at 22:02
I found some code at the link below, but holy cow – is that a lot of code to simulate the previous 1 line of code in v2 of the API. lootogo.com/googlemapsapi3/markerPlugin.html
Oct 9, 2009 at 16:17
remember that maps 3.0 is meant to be VERY light in order for mobile devices to use it with as little lag as possible…
Oct 9, 2009 at 17:52
The solutions suggested here appear to be broken as of 2010/07/29. I wish I had a working version to suggest instead.
Jul 29, 2010 at 22:59
The highest rated answer is wrong. View source on this example to see how to do it: google-developers.appspot.com/maps/documentation/javascript/…
Apr 17, 2012 at 12:49
Please take a look at this page gmaps-utility-library.googlecode.com/svn/trunk/markermanager/…
Jun 23, 2012 at 5:46
|
Show 1 more comment | https://coded3.com/google-maps-api-v3-how-to-remove-all-markers/ | CC-MAIN-2022-40 | refinedweb | 783 | 64.71 |
Helmchen: Gay marriage ruling a bittersweet victory
SATURDAY, NOVEMBER 9, 2013
The only daily newspaper published in McHenry Co.
News, A2
75 CENTS
PREP FOOTBALL
HUNTLEY INTERCHANGE
Harvard dominates Chicago King Prep Extra, 1
State, local officials celebrate opening Local&Region, B1
Judge backs approval of Centegra plan
HOMEOWNER FOUND IN LAS VEGAS
Skeletal remains bring charges
WILLIAM J. ROSS
Lawsuit delayed Huntley project By EMILY K. COLEMAN ecoleman@shawmedia.com
Kyle Grillot – kgrillot@shawmedia.com
Police from the McHenry County Sheriff’s Office don protective masks and footwear Thursday before entering a house on the 500 block of North Country Club Drive near McHenry as they collect evidence. The owner of the home, where the skeletal remains of a woman were found earlier this week, has been charged with concealing her death, according to the sheriff’s office.
Man in custody accused of concealing homicide
ve. nt A e c s Cre Ave. lotte r a h C Ave. Victoria
FOX RIVER
Virginia Ave.
518 N. Country Club Drive, where skeletal remains of a woman were found this week
UNINCORPORATED McHEN po-
Kyle Grillot – kgrillot@shawmedia.com
56 32 Complete forecast on A10
lice.
GIRLS PREP VOLLEYBALL
CL SOUTH ONE WIN AWAY FROM STATE At the beginning of the season, the Crystal Lake South volleyball team set a goal to reach the state semifinals, and the team is one win away from reaching that goal. At 6:30 p.m. Saturday, the Gators will face Lake Zurich in the Class 4A Huntley Supersectional with a chance to appear in next weekend’s state tournament. For more, see page C1.
David Cormalleth
LOW
N
Northwest Herald graphic
LOCALLY SPEAKING
HIGH
Drive
lsynett@shawmedia.com
N. Country Club
By LAWERENCE SYNETT
CRYSTAL LAKE: Ceremony at McHenry County College celebrates area veterans. Local&Region, B1 Vol. 28, Issue 313
Where to find it Advice Business Buzz Classified
B6 E1-2 B8 E3-8
Comics B7 Local&Region B1-4 Lottery A2 Movies B5
Obituaries Opinion Puzzles Sports
B4 A9 E7 C1-6
HUNTLEY – Centegra Health System cleared another hurdle in its efforts to build a new hospital in Huntley. Will County Judge Bobbi Petrungaro backed the Illinois Health Facilities and Services Review Board’s approval of the $233 million project in a decision issued Friday. The Oct. 23 groundbreaking on the 128-bed acute care hospital was delayed because of a yearlong lawsuit filed by competitors Mercy Health System, Advocate Health Care and Sherman Health after the state board reversed two previous rejections of Centegra’s application. “During this three-year process, we remained confident that this hospital project was in the best interest of the residents who call our community home,” Centeg-
ra’s chief executive officer, Mike Eesley, said in a news release. The complaints filed by the three competitors contended that the ruling should be reversed because Department of Public Health staff said the proposal did not meet three of the state’s 20 standards, including there being a need in McHenry County for the proposed project and that it does not unnecessarily duplicate health care and clinical services in the area. The state board disagreed with the staff assessment, determining that, with growth for the area estimated at 13 percent, the project would meet future need. Despite the lawsuit, Centegra has been moving ahead with the design and permitting processes. Detailed designs presented to the Huntley Plan Commission show a five-story
See CENTEGRA, page A7
Jury deadlocks on arson charges By JIM DALLKE jdallke@shawmedia.com WOODSTOCK – After deliberating more than nine hours, a jury found Joseph Ziegler guilty of burglarizing a Pistakee Highlands home but could not reach a verdict on the fire that left the home uninhabitable. The prosecution argued the fire was the end result of an Aug. 8, 2012, argument between Ziegler and Nick Pennington, who lived at 5107 Westwood Drive in Pistakee Highlands. The burglary conviction carries a potential prison term of up to seven years, while the arson charges carry a minimum prison sentence of six to 30 years. Ziegler could be retried on the arson charges. Prosecutors said Ziegler believed Pennington stole
Joseph Ziegler was found guilty of burglarizing a Pistakee Highlands home, but the jury could not reach a verdict on the fire that left the home uninhabitable. his drugs, and vowing revenge, Ziegler tried to burn Pennington’s home. But they said Ziegler missed his target and instead.
See ARSON, page A7.
Saturday, November 9, 2013 • Northwest Herald • NWHerald.com
GENERAL INFORMATION: 815-459-4040
Equality bill marries joy, sorrow in single day It’s often called the happiest day of your life, a day you’ll never forget: your wedding day. But, as a gay man living in Illinois, it was a day I would never experience. Actually, it was a day I wasn’t “allowed” to experience. Until this week, same-sex couples could not legally marry in this state. On Tuesday, that all changed. Following an emotional 61-54 vote in the Illinois House, marriage equality for gay and lesbian couples soon will become a law of the land in the Land of Lincoln. I watched in awe as the historic vote made Illinois the largest of the 15 states to allow gay marriage, a sign of Americans’ increasing acceptance of homosexuality. Or at least of our rights. The measure now heads to Gov. Pat Quinn, who has said he will sign it into law. “Today, the Illinois House put our state on the right side of history,” said Quinn, who campaigned for the measure, which is scheduled to take effect in June. But, for me, this victory was bittersweet.
8LOTTERY
VIEWS Scott Helmchen While I was thrilled my partner and I will be getting hitched, something was missing. My dad, who died in 2003. Each milestone I reach and accomplishment I make in my life triggers a memory of him. Tuesday was no different. “I wish he would’ve lived long enough to see this day” kept running through my mind. I then realized the best I can do to honor my dad’s memory is to be a man he would be proud of. I do that by treating others as I want to be treated, as my equal. This new marriage equality law does just that for the gay and lesbian community. “At the end of the day, what this bill is about is love, it’s about family, it’s about commitment,” bill sponsor state Rep. Greg Harris said. Opponents of the new law (including some of the most powerful
religious leaders in Illinois) believe marriage should remain between a man and a woman. I don’t get it. How does allowing me the right to marry the man I love affect your own marriage? State Rep. Jack Franks, D-Marengo, the only McHenry County legislator to support the bill, agrees. In announcing his “yes” vote this week, Franks said he “can’t think of a single way” approving gay marriage would hurt his own marriage to his longtime wife. “This is not the time to be timid,” Franks said. “Those waiting have waited long enough.” Right on, Jack. Even Pope Francis created some waves in July when he said the Roman Catholic Church had become too focused on its opposition to homosexuality. “If a person is gay and seeks God and has goodwill, who am I to judge him?” he said. Other opponents have said this push for marriage equality is about destroying religious freedoms. It’s not. It’s about giving two consenting
adults, regardless of orientation, the right to wed. House Speaker Michael Madigan says he thinks the country “is at the point where not only is this accepted, it’s expected.” Marriage is a core, inalienable right for everyone, bestowed by the Declaration of Independence itself. Gay people shouldn’t be “allowed” to be married; we have the right to be married. You can have as many debates about gay marriage as you want, and I certainly have had my share. But, to me, marriage should be marriage: a recognition and celebration of the love between two people. So, today, with our community’s emblematic rainbow flag flying a little bit higher, my partner and I celebrate this historic vote for our state and our family. After all, love is love, no matter who the people are. I know my dad would agree.
8NORTHWEST OUTTAKES
8CONNECT WITH US facebook.com/nwherald @nwherald
Kyle Grillot – kgrillot@shawmedia.com
The Cary-Grove football team greets fans Oct. 18 after a game against Crystal Lake South. Cary-Grove won the game, 21-14. Cary-Grove hosts Boylan on Saturday in the second-round Class 6A football playoff game.
LIKE WHAT YOU SEE? Check out our gallery of images made by Northwest Herald photographers on the Northwest Herald Facebook page at. Photos also can be purchased at.
CBS admits error in Benghazi ‘60 Minutes’ story
NEW YORK – As-
By DAVID BAUDER The Associated Press
SM
Bill Hartmann
...We Take the Time to Know You
26% 20% Fair
20% Great
FAMILY ALLIANCE
servative Threshold Editions imprint two days after the “60 Minutes” story. Davies had written the book under the pseudonym Morgan Jones, which is how “60 Minutes” identified him in Logan’s story about Benghazi..
Bill Hartmann.
“Serving our communities to make them better places to live.”
Voted Best of the Fox again for 2013 Medically supervised weight loss program! • On average patients lose 20 lbs. • Releana® Weight Loss Hormone • Safe, natural, effective • 8 week in office program supervised by the Doctors at Woman to Woman
Best of the Fox Special Offer
50% OFF
Family Alliance announces the addition of Primary Care Services and welcomes to its staff Rex C. Nzeribe, MD, Fellowship-Trained Geriatrician and Internal Medicine Physician.
Vice President
Call for an appointment:
(815) 788-3402
(815) 338-3590
Commercial Lending Services Center 611 S. Main Street Crystal Lake, IL 60014
8CORRECTIONS & CLARIFICATIONS
Trust Your Weight Loss To The BEST!!
Comprehensive Care Services
Poor Good con-
INC.
34%
sociated
Count On Me...
Friday’s results:
What do you think of your workplace culture?
CLASSIFIED To place an ad: 815-455-4800 or 800-589-8237
Do you have a news tip or story idea? Please call us at 815-459-4122 or email us at tips@nwherald.com.
Get news from your community sent to your phone. Text the following keyword to 74574 for your community text alerts:
How often do you take I-90?
VP AUDIENCE DEVELOPMENT Kara Hansen 815-459-8118 khansen@shawmedia.com
8CONTACT US
8TODAY’S TALKER
The Northwest Herald invites you to voice your opinion. Log on to www. NWHerald.com and vote on today’s poll question:
MARKETING DIRECTOR Katie Sherman ksherman@shawmedia.com
SUBSCRIPTION INFORMATION Daily: $.75 / issue Sunday: $1.75 / issue Basic weekly rate: $6.25 Basic annual rate: $325
8NEWS ALERTS
Northwest Herald Web Poll Question
DISPLAY ADVERTISING 815-459-4040 Fax: 815-477-4960
MISSED YOUR PAPER? Please call by 10 a.m. for same-day redelivery
Powerball Est. jackpot: $87 million
Message and data rates apply.
ADVERTISING DIRECTOR Paula Dudley pdudley
Mega Millions Numbers: 41-42-51-57-65 Mega ball: 7 Megaplier: 2 Est. jackpot: $115 million
Wisconsin Lottery Pick 3: 0-9-8 Pick 4: 7-0-2-8 SuperCash: 16-19-26-27-35-36 Badger 5: 5-14-22-24-25
EDITOR Jason Schaumburg 815-459-4122 jschaumburg@shawmedia.com
NEWSROOM Telephone: 815-459-4122 Fax: 815-459-5640
• Scott Helmchen is the features editor of the Northwest Herald. Reach him at 815-526-4402 or email him at shelmchen@shawmedia.com.
Illinois Lottery Pick 3 Midday: 4-6-1 Pick 3 Evening: 5-8-3 Pick 4 Midday: 7-8-3-9 Pick 4 Evening: 7-2-9-9 Lucky Day Lotto midday: 4-25-26-29-34 Lucky Day Lotto evening: 4-5-9-22-27 Lotto jackpot: $4 million
Indiana Lottery Daily 3 Midday: 9-9-8 Daily 3 Evening: 5-4-5 Daily 4 Midday: 7-7-2-0 Daily 4 Evening: 0-7-1-0 Mix and Match: 3-5-27-30-39 Est. jackpot: hghghg
PRESIDENT AND PUBLISHER John Rung jrung@shawmedia.com 815-459-4040
ALL LASER SERVICES! Offer ends soon.
WOMAN TO WOMAN Obstetrics and Gynecology, PC
260 Congress Parkway, Suite A (Across from the Post Office, next to Health Bridge Fitness Center) Crystal Lake, Illinois
815.477.0300 2028 N Seminary Avenue • Woodstock, IL
All Women Staff
“We can relate to your needs because women understand women.”
Northwest Herald / NWHerald.com
STATE
Saturday, November 9, 2013 • Page A3
Quinn picks Paul Vallas as running mate The ASSOCIATED PRESS CHICAGO – Working.
Report finds friend of Jesse White double-billed Illinois By JOHN O’CONNOR The Associated Press
AP photo
This combination made from file photos shows Willis Tower (left), formerly known as the Sears Tower, in Chicago on March 12, 2008, and 1 World Trade Center in New York on Sept. 5. Soaring above the city at 1,776 feet, the 104-story 1 World Trade Center is in contention with Willis Tower for title of America’s tallest building.
Height of 1 World Trade Center debated in Chicago By JASON KEYSER The Associated Press CHICAGO –foot cur-
rent.
SPRINGFIELD – A friend of Secretary of State Jesse White’s claimed during her time as his chief deputy director of securities that she also worked five hours each workday as a home health care provider, an internal investigation found. Marlene Liss, 36, also falsely claimed to have bachelor’s and master’s degrees, reported a fake address and has used at least nine different names in public records, the report by the secretary of state’s inspector general found. She was paid $80,000 per year under White, who knew her professionally from a print shop she operated and who was a friend of hers, spokesman Dave Druker said. Federal prosecutors are investigating the matter, according to the report and a spokeswoman for the Illinois Department of Human Services. Liss has received payments as a personal care
assistant for about 20 years, most recently for helping a blind person in Chicago. She makes $11.65 an hour and claimed she worked from 7 to 9 a.m., 1 to 3 p.m., and 6 to 7 p.m. daily – at least three hours of which, not counting commuting time, overlapped with hours she repeatedly had reported as working for the secretary of state’s office. She was fired in September when the inspector’s report was finished, but she remains on the Human Services payroll. “Regardless if any employee knows the secretary or not, unethical conduct will not be tolerated and people in violation will lose their positions as was the case here,” Druker said. Human Services spokeswoman Januari Smith said she could not comment because of the investigation, which also involves the state police and the U.S. Department of Health and Human Services. Liss does not have a published phone number and
could not be contacted. Liss began working for White in June 2010, according to the inspector general’s report, which was first reported this week by Crain’s Chicago Business. In December 2010, she moved to the securities department, which regulates the securities industry and protects investors. Using a conservative estimate of three overlapping hours, the inspector general found that White’s office paid Liss for 444 duplicate work hours – when she reported being at both the secretary of state’s office and the health care client’s home – from December 2012 to July 2013. In addition to her $80,000 salary, state records indicate Liss received $21,000 from Human Services in 2012 and so far this year, $18,400. When she applied for a secretary of state’s job in June 2010 and later for the chief deputy director’s post, Liss reported receiving bachelor’s and master’s degrees from Loyola University, but the school has no such records.
Bountiful
LIGHTING & home
st
1
Anniversary Sale
Come see our large selection of lighting and our beautiful custom Christmas decor!
Bountiful
LIGHTING & Home
661 S. Main St. • Crystal Lake • 815-356-6004
(Located inside Mayfair Furniture)
Page A4 • Saturday, November 9, 2013
NATION
Northwest Herald / NWHerald.com
Few options for Obama to fix cancellations By RICARDO ALONSO–ZALDIVAR ap-
pear.”
New rule demands parity for mental health coverage By KEVIN FREKING The Associated Press
AP photo
Secretary of State John Kerry smiles as he arrives Friday at Geneva International Airport in Switzerland for closed-door nuclear talks at the United Nations offices.
Kerry mounts diplomatic push on Iran nuclear talks The ASSOCIATED PRESS GENE latenight.
WASHINGTON –of.
120,1(( 1DPHBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB +RPHWRZQ B :RUNSODFH BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB
120,1$725
1DPHBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB 3KRQHQXPEHU BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB (PDLO BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB
Saturday, November 9, 2013 • Page A5
Northwest Herald / NWHerald.com
THE ALL NEW 2014 CHEVY’S HAVE ARRIVED! Impala, Malibu, Cruze, Spark, Sonic, Volt, SS, Camaro, Corvette, Equinox, Traverse, Tahoe, Suburban, Colorado, Avalanche, Silverado. They Are All Here!
:BW^ gV tVr J^?> 9@Z=^ J[^ ;XX c^< jlkSb? cB<U
jlkS :h8GD :LIC8 9g8K8e
THE BEST CHOICE!
uB@ Kt=ZV\?p K^X^s>ZBV tVr K^@=Zs^U
0% APR FOR 72 MONTHS FINANCING ON NEW CHEVY VEHICLES! ^
NEW 2014 CHEVY CRUZE LS
149 EjpjkN
CHEV Y MALIBU MALIBU LS LS NEW 2014 CHEVY
$ LEASE FOR
TQ dacJhK
$ `8L dacJh† DUE AT SIGNING
Includes security deposit Tax, title, license and dealer fees extra Mileage charge of 25¢/mile over 12,000 miles per year. MSRP: $19,180+, Stk: #12704
LEASE FOR
179 ETplQN
TQ dacJhK
NEW 2014 CHEVY EQUINOX FWD LS
$
`8L dacJh† LEASE FOR
DUE AT SIGNING
209 ETpljN
TQ dacJhK
Includes security deposit Tax, title, license and dealer fees extra Mileage charge of 25¢/mile over 12,000 miles per year. MSRP: $23,080+, Stk: #12597
`8L dacJh†
DUE AT SIGNING
Includes security deposit Tax, title, license and dealer fees extra Mileage charge of 25¢/mile over 12,000 miles per year. MSRP: $25,315+, Stk: #12625
j D8;LmjSplll dge8
FREE d;gcJ8c;c:8 NEW 2014 CHEVY TRAVERSE FWD LS
259 ETpRjN
$ LEASE FOR
TQ dacJhK
`8L dacJh†
DUE AT SIGNING
Includes security deposit Tax, title, license and dealer fees extra Mileage charge of 25¢/mile over 12,000 miles per year. MSRP: $32,220+, Stk: #12685
ac ;ee c8F jlkS :h8GD da98eK
NEW 2014 CHEVY IMPALA LT
NOW AT d;LJgc :h8GD :LDKJ;e e;f8††
CERTIFIED PRE-DRIVEN VEHICLES AVAILABLE! SEE OUR IN-HOUSE CREDIT SPECIALIST! ASK FOR LOU
SE HABLA ESPAÑOL! ASK FOR HERB PEREZ
269 EjpPQN
$ LEASE FOR
TQ dacJhK
`8L dacJh†
DUE AT SIGNING
Includes security deposit Tax, title, license and dealer fees extra Mileage charge of 25¢/mile over 12,000 miles per year. MSRP: $29,920+, Stk: #12763
$N
nNR :;ee uaL ;``agcJd8cJ
OIL CHANGE bYCE Ds@ J E\IH ECHHY[`Ej NoWD\`D[qE J p[`E`YE `@DFsj MH DI T GDEj ?sWWID r` qIXr[W`p A[D\ sWo ID\`F I__`Fj bY`sE` HF`E`WD qICHIW sD D[X` I_ AF[D`kCHj =@j ggiVhigVj
CHECK OUT OUR INVENTORY AT MARTIN-CHEVY.COM SEE OUR IN-HOUSE CREDIT SPECIALIST! ASK FOR LOU
9acbJ uaLi8J Jh8 9;KhU H d;LJgco:h8GDn:ad
OOOnSONnkROR
Rjjl cB@>[<^?> h<q H :@q?>tX etY^p ge KtX^?M dBVou@Z NtWoNAW Kt> NtWoQAW K^@=Zs^ dBVou@Z PtWoPAW Kt> OtWoTAW
bYCE Ds@l D[DY` Y[q`WE` J KgSUjVh pIq _``j tL[D\ sHHFIB`p qF`p[Dj cW E`Y`qD XIp`YEj eW Y[`C I_ XsWC_sqDCF`F F`rsD`E sWp XsWC_sqDCF`F [Wq`WD[B`Ej =@P KgVjRQ H`F Kglhhh ZWsWq`p A[D\ Kh pIAWj †Plus tax, title, license and doc fee. Lessee responsible for maintenance, repairs/liability in event of early lease termination. With approved credit. An extra charge may be imposed at the end of the lease r`DA``W D\` F`E[pCsY BsYC` I_ D\` Y`sE`p HFIH`FDo sWp D\` F`sY[n`p BsYC` sD D\` `Wp I_ D\` Y`sE` D`FXj ]]usqDIFo HFI^FsXj N`` p`sY`F _IF p`Ds[YEj mdNOb Xso WID r` HF[q` sD A\[q\ B`\[qY` [E EIYp _IF [W trade area. >`sY`F A[YY WID \IWIF sWo HF[q[W^ `FFIFE [W D\[E spB`FD[E`X`WDj bF[q`E sF` ^IIp f psoE _FIX psD` I_ HCrY[qsD[IWj b[qDCF`E sF` _IF [YYCEDFsD[IW HCFHIE`E IWYoj N`` p`sY`F _IF p`Ds[YEj
NATION & WORLD
Page A6 • Saturday, November 9, 2013
Northwest Herald / NWHerald.com
More lenient lice policies bug some parents By JENNIFER C. KERR The Associated Press
AP photo
A house is engulfed Friday by the storm surge brought about by powerful Typhoon Haiyan that hit Legazpi city, Philippines, about 325 miles south of Manila.
More than 100 dead in typhoon in Philippines The ASSOCIATED PRESS
61 Polaris Drive Lake in the Hills
847-658-4677
A Un Uniq Unique iq R Resale al Sh Shop op
Anything you might find in an attic...... at the
Just North of Ashley Furniture and The Great Escape
Mon - Fri: 11:00 am - 7:00 pm Sat: 11:00 am - 5:00 pm Sun: 12:00 pm - 5:00 pm
Check Us Out On
Tues thru Sat 10am-6pm
Bicycle Sales And Service Join The Republic
planitnorthwest.com
2397 S. Randall Rd. • Algonuin, IL • (224) 699-9589
• Traditional Chinese Medicine and Acupuncture • Traditional Martial Arts & Self Defense • Yoga • Tibetan Meditation • Creative Development • Wellness Programs …as well as other activities 1540 Carlemont Drive • Crystal Lake, IL 60014 • (815) 444-6019 Licensed and Board Certified
Read all about it ...
Sunday Fashion, home decorating, gardening, announcements and more! more.
FREE NECK & BACK PAIN WORKSHOP.
WASHINGTON – Some schools are letting kids with live lice in their hair back in the classroom, a less restrictive policy that has parents scratching their heads. “Lice is icky, but it’s not dangerous,” said Deborah Pontius, the school nurse for the Pershing County School District in Lovelock, Nev..
Q: What are lice?: Why the change in policy? A: Itchy children probably had lice for three weeks to two months by the time they’re sent to the nurse, Pontius said. Classmates already would have been exposed. There’s little additional risk of
transmission, she says, if the student returns to class for a few hours until the end of the day, when a parent would pick up the child and treat for lice at home. Parents with elementary school-aged kids should check their children’s hair for lice once a week anyway, Pontius said.
Q: What do the experts say? A: The American Academy of Pediatrics updated its guidelines in 2010 to adopt a “do not exclude” infested students recommendation for schools dealing with head lice. It has long encouraged schools to discontinue “nonit”.
Q: How do parents feel? A: Letting kids with untreated lice remain in class doesn’t sit well with some parents. “I’m appalled. I am just so disgusted,” said Theresa Rice, whose 8-year-old daughter, Jenna, has come home from her Hamilton County, Tenn., school with lice three times since August. “It’s just a terrible headache to have to deal with lice.” To pick out the tiny nits and lice from Jenna’s hair is a four-hour process. Add to that all the laundry and cleaning – it’s exhausting, she said. Jenna’s school implemented a.
Discover a non-surgical approach to relieve neck & back pain Do you want to feel your best and live life to the fullest without back, neck or leg pain? With our program, you’re on your way to enjoying a higher quality of life FREE of back pain. We treat low back pain, herniated discs, bulging discs, degenerative joint disease and sciatica. Millions of Americans have discovered this breakthrough treatment - let us help you. There is one reason that medical doctors, chiropractors, orthopedic doctors and therapists are using this technology…
IT WORKS!
Seminar topics will include: • • • • • •
Causes of back pain and why you might be suffering Why many treatments won’t work What treatments are effective Learn the latest approaches medicine has to offer Why some people do not qualify for this type of care Why our treatment model is so effective
Enjoy a complimentary dinner and discover how to live life FREE of neck and back pain For you and a guest
Join us At
The Village Squire 4818 Northwest Hwy • Crystal Lake, IL 60014
Monday November 11 at 6:30pm SEATING IS LIMITED! Call 815-408-9976 TODAY and give the RSVP Code 503 to secure your reservation. Invitation is limited to first time guests only. All attendees must be 18 or older.
NEWS
Northwest Herald / NWHerald.com
Saturday, November 9, 2013 • Page A7
Status hearing for Fight with Mexican cartel small victory retrial set Wednesday By KATHERINE CORCORAN The Associated Press
• ARSON Continued from page A1 the GPS belonged to her and was inside her GMC Envoy before the vehicle was destroyed in the fire. The prosecution presented multiple witnesses who testified that Ziegler had a verbal altercation with Pennington the night before the fire. After the argument, one witness – Devon Weber – said Ziegler
told him. by Dakota Wilkinson as repayment for drugs. A status hearing for a retrial has been scheduled for Wednesday.
Centegra expects to hire 1,000 employees • CENTEGRA Continued from page A1 hospital with 100 surgical beds, an eight-bed intensive care unit, a full-service emergency department and a helipad for transporting critical-needs patients. The system plans on breaking ground in the spring with the hospital opening still planned for 2016, Eesley said. Before that can happen, though, Centegra needs final approval from the village of Huntley and to wrap up its final financing phase, said Susan Milford, Centegra’s se-
nior vice president for strategy and development. Centegra estimates the project will create 800 construction jobs and expects to hire 1,000 employees to staff the proposed Centegra Hospital – Huntley. The local economic impact from the construction, salaries and the purchase of medical equipment and furnishings is estimated at $197 million, according to the release. Mercy Health System has not decided whether it will appeal the decision, Mercy Vice President Richard Gruber said.
“The little store that pays you more!”
Now Open in South Elgin
$
Get the most green for your silver and gold! Coins • Gold • Silver
TRI COUNTY COINS & COLLECTIBLES
Visit our resale shops for Vtg. Jewelry & Decor! 111 N. MAIN ST (RTE. 47), ELBURN • 630-365-9700 228 S. RANDALL RD, SOUTH ELGIN • 847-697-2646
TRICOUNTYCOINS.COM
815-477-7766 weatherwiseheating.com world’s best hearing aid! At least I think so. And I think you’ll agree. As a dedicated hearing specialist, I have one primary goal. “I want you to hear as well as you possibly can.” hat is why I am pleased that you can try what is arguably the best hearing aid made in the United States, the Starkey 3-Series i110. And for a very short time, it’s yours for an unbeatable low price! Your hearing is important. Please don’t settle for anything but the best – the Starkey 3-Series i110 and world class service from your friends at Hearing Help Express. But, don’t wait! his special ofer is only good until November 18, 2013 and will not be repeated.
J�� Madig�� Illinois Licensed Hearing Specialist
i110 by
★ Small and discreet ★ Speech is easier to understand in noisy situations ★ No buzzing or whistling ★ Risk-FREE offer ★ 45-day home trial
©Hearing Help Express®, Inc.
✔Trained Professionals ✔24-Hour Dedicated Service Department ✔Same Day Service ✔100% Satisfaction Guarantee ✔Custom Installations ✔Family Owned & Operated since 1985
NO FUEL SURCHARGE
$
69
FURNACE CLEAN & CHECK
GUARANTEED NO BREAKDOWNS
by certified techs • save $60 Cannot be combined with any other offer, rebate or coupon. One coupon per customer only. Expires 11-30-13.
WeatherWise is proud to maintain a 99.9% csi (customer satisfaction index), monitored by an independent clearinghouse.
Imagine cutting your energy bill by 50%! • Air Seal Your Home • Insulate Your Attic/ Crawl Space/Bonus Room with Spray Foam Insulation
START SAVING IMMEDIATELY
Active Foam Specialists 847-497-9480
Must present coupon at time of estimate. Not valid with other specials or coupons. Offer expires 12/31/13
847-497-9480
but only HUGE s y a d w e f t x e n e SAVINGS... for th Starkey
i 110
Average retail price
Our every day low price
$5,890
$3,998
per pair
per pair
YOU SAVE only
40%
$3,498
per pair
Expires 11/18/13 Not valid with any other ofer.
Schedule your appointment today!
Call (847) 515-2003 ext. 87-925
This free planner includes tips, hot trends, vendors and the all-important wedding planning checklist.
Pick up your FREE Bridal Planner Today!
Northwest Herald 7717 S. Route 31, Crystal Lake For more information, call 815-459-4040
Hearing Help Express • 11800 Factory Shops Blvd, Ste 645 • Huntley, IL 60142
Page A8 • Saturday, November 9, 2013
Northwest Herald / NWHerald.com
Opinion
John Rung President and Publisher
Dan McCaleb Group Editor
Jason Schaumburg Editor
Saturday, November 9, 2013 • Page A9 • Northwest Herald • NWHerald.com 8THUMBS UP, THUMBS DOWN
8SKETCH VIEW
Thank you, U.S. veterans The.
8HOW CONGRESS VOTED A look at this week’s major votes in Congress and how those who represent McHenry County voted:
Anti-gay bias in the workplace The purpose: A bill to prohibit employment discrimination on the basis of sexual orientation or gender identity. The vote: Passed in the Senate on Thursday by 15 votes – 64 voted “yes,” 32 voted “no,” and four didn’t vote. Local representation: U.S. Sens. Dick Durbin (D) and Mark Kirk (R) voted “yes.”
8IT’S YOUR WRITE Donation
Scott F. Migaldi
Source: The New York Times’ Inside Congress website
Cary
Those who don’t understand
8ANOTHER VIEW
It’s about lax gun laws The authorities cannot be accused of underreacting to the shootings at LAX. If anything, quite the opposite, given how many flights were canceled and passengers delayed in the hours after a tragedy that was quickly contained.old accused of killing TSA agent Gerardo Ismael Hernandez to express conspiracist grievances, apparently made legal purchases of the Smith and Wesson M&P .223-caliber assault rifle used at LAX. Discussions should include whether changes in firearm policies could have made the mayhem less likely. Terminal 3 at LAX joins the list of notorious gun-crime scenes of just the past three years, alongside Tucson, Ariz.; Aurora, Colo.; Oak Creek, Wis.; Newtown, Conn.; Santa Monica, Calif.; and the Washington, D.C., Navy Yard. These are only the shootings that capture the public’s attention, because of where they occur, the body count and who was shot. They don’t include the murders that never make headlines. But the suggestion that Los Angeles International add passenger checkpoints, moving the security perimeter beyond where these shootings took place, is pointless. Wherever the first line of security is, that’s where an armed person could do his or her damage. The goal must be for air travelers to feel safe but not feel like victims of oppressive security. The sad fact is that this isn’t about airports. It’s about shootings anyplace that will happen as long as the nation shrugs and gives up trying to keep guns away from the wrong people. San Bernardino County (Calif.) Sun
Editorial Board: John Rung, Don Bricker, Dan McCaleb, Jason Schaumburg, Kevin Lyons, Jon Styf, Kate Schott, Stacia Hahn,
Stumbling country To the Editor: I just retired from a police department after 28 years. I have a pension that provides no free insurance or any other outstanding benefits that have been the topic of reform the past few years. The years have opened my eyes
How to sound off We welcome original letters on public issues. Letters must include the author’s full name, home address and day and evening telephone numbers. We limit letters to 250 words and one published letter every 30 days. All letters are subject to editing.
for length and clarity at the sole discretion of the editor. Submit letters by: • E-mail: letters@nwherald.com • Mail: Northwest Herald “It’s Your Write” Box 250 Crystal Lake, IL 60039-0250
Closer look at District 155 union numbers,
GUST VIEW Paul Kerseypicked..
8THE FIRST AMENDMENTonly.
Congress shall make no law respecting an establishment of religion, or prohibiting the free exercise thereof; or abridging the freedom of speech, or of the press; or the right of the people peaceably to assemble, and to petition the Government for a redress of grievances.
Weather
Saturday, November 9, 2013 Northwest Herald Page A10
Text the keyword NWHWEATHER to 74574 to sign up for daily weather forecast text alerts from the Northwest Herald. Message and data rates apply.
TODAY
SUN
MON
TUE
WED
THU
FRI
56
47
47
33
36
42
49
Partly sunny and cold
Mostly sunny and a little warmer
Mostly sunny and more seasonal
Mostly sunny and much colder
Partly sunny, windy and mild
Wind:
Wind: W/SW 15-25 mph
W 10-20 mph
Increasing clouds Mostly cloudy and cold with a flurry with a few light or two showers Wind: Wind:
N/NW 5-15 mph
32
34
ALMANAC
N/NW 5-15 mph
26
Wind:
Wind:
W/SW 5-15 mph
S/SW 5-15 mph
23
26
30
36
Shown is today’s weather. Temperatures are today’s highs and tonight’s lows.
at Chicago through 4 p.m. yesterday
Harvard 54/29
Belvidere 55/30
TEMPERATURE HIGH
Wind:
SW 5-10 mph
Crystal Lake 56/32
Rockford 56/30
LOW
McHenry 56/31
Hampshire 56/31
90
Waukegan 55/32 Algonquin 56/30
Oak Park 58/33
St. Charles 56/32
DeKalb 56/32
88
Dixon 59/28
LAKE FORECAST WATER TEMP: Chicago Winds: WSW at 12-25 kts. 58/33 Waves: 3-6 ft.
52
Aurora 59/30
Sandwich 59/31
39
Hold on to your hats as a cold front moves through. A sprinkle or two is possible, but winds could gust up to 30 mph out of the west and southwest. Low temperatures will dip near freezing by Sunday morning. Temperatures will take a nose dive Sunday as a Canadian high pressure system moves in. A clipper system will arrive Monday into Tuesday with some showers and flurries.
Orland Park 59/32 Normal low
36°
Record high
73° in 1931
Record low
11° in 1991
Q.
In a year, do all places on Earth get about the same duration of sunlight?
?
PRECIPITATION 24 hours through 4 p.m. yest.
0.00”
Month to date
0.73”
Normal month to date
0.82”
Year to date
38.79”
Normal year to date
32.31”
SUN AND MOON
REGIONAL CITIES
WEATHER TRIVIA™
Yes.
52°
A.
Normal high
FOX RIVER STAGES as of 7 a.m. yesterday Flood
Current
24hr Chg.
Fox Lake
--
4.04
-0.01
Nippersink Lake
--
3.97
-0.01
10
6.59
-0.09
Sunrise
6:36 a.m.
New Munster, WI
Sunset
4:37 p.m.
McHenry
4
1.61
+0.03
Moonrise
12:12 p.m.
Algonquin
3
1.72
+0.01
Moonset
11:08 p.m.
Today
MOON PHASES First
Full
Nov 9
Nov 17
New
Nov 25
Dec 2
5p
0-2 Low; 3-5 Moderate; 6-7 High; 8-10 Very high; 11+ Extreme
64/41/s 34/34/c 62/42/pc 52/47/pc 54/37/s 46/34/c 58/38/pc 49/41/pc 60/38/s 62/38/s 56/40/pc 72/52/pc 63/34/s 59/31/s 56/38/c 72/46/s 30/27/c 39/24/pc 48/30/c 85/72/pc 74/53/pc 62/35/s 71/56/c 61/37/s 72/50/s 74/54/s 61/40/s 64/46
83/75/sh 55/34/pc 45/27/pc 63/41/s 73/60/c 50/41/pc 57/44/s 68/45/s 80/65/pc 52/42/pc 83/59/s 54/39/pc 52/43/sh 64/34/s 59/42/s 73/41/s 66/39/s 74/57/pc 67/54/pc 65/49/pc 48/43/sh 48/23/pc 66/40/s 45/26/pc 82/65/pc 81/55/s 57/42/s 65/40/s
Monday
58/32/pc 59/30/pc 62/33/s 64/37/s 62/34/s 58/33/pc 62/33/s 57/35/pc 60/32/s 59/32/pc 61/33/s 63/35/s 56/31/pc 62/33/s 61/32/s 56/30/pc 61/29/s 64/33/s 55/32/pc 57/31/pc
48/33/s 47/31/s 48/34/s 56/32/s 50/31/s 48/34/s 49/32/s 47/37/s 48/32/s 48/32/s 48/33/s 54/29/s 47/31/s 50/33/s 49/32/s 46/32/s 48/32/s 50/32/s 46/32/s 48/32/s
42/24/c 44/18/c 49/23/pc 61/33/pc 51/27/pc 43/26/c 51/25/pc 44/27/c 44/21/pc 44/23/c 48/25/pc 59/32/pc 43/22/c 48/23/pc 43/21/pc 41/21/c 42/20/c 51/24/pc 42/22/c 43/23/c
91/75/pc 48/37/sh 74/55/s 80/62/t 61/28/c 47/39/pc 48/38/sh 75/61/t 78/59/pc 84/77/t 48/37/sh 52/41/pc 84/75/c 77/50/s 64/50/s 63/31/s 89/78/t 71/60/pc 48/39/r 57/43
87/76/t 59/47/sh 75/52/pc 41/37/pc 46/41/sh 75/61/pc 48/43/r 72/60/sh 72/45/pc 80/61/pc 55/42/r 86/77/t 45/37/r 86/55/s 78/62/s 58/54/pc 49/36/sh 49/40/c 54/43/r 52/402013
$30 OFF
Pre-Season Furnace Sale! High Efficiency Furnace
Any S A Service i Call C ll
Starting at
$1,600.00 or NWH
Today
Sunday
Showers T-storms
Rain
Flurries
Proudly serving the North & NW suburbs for over 65 years
Expires 11/30/13. Must present coupon and cannot be combined with any other offers or discounts
WORLD CITIES
Today
$24.95 mo.
FREE ESTIMATES
NWH
AEROSEAL DUCT SEALING Save up to 30%
NWH
of Air Loss in Your Duct System (Call for FREE Estimate)
Snow
Cold Front
Ice
Warm Front
Don’t “leaf” your furnace unchecked for another year, Call us now to schedule your appointment.
FURNACE Clean & Check $89.95
Expires 11/30/13. 11/30/1 0/13. 0/1 3. Mus Mustt pres ppresent resent ent co coupo coupon upon and cannot be combined with any other offers or discounts
800-350-HVAC (4822)ficialhvac.com
NWH
Lexie Kern OFFICIAL Spokesdog Director of Security
Stationary Front
Local&Region
SECTION B Saturday, November 9, 2013 Northwest Herald
Breaking news @
News editor: Kevin Lyons • kelyons@shawmedia.com
8COMMUNITY NEWS
SCRAP-A-PALOOZA AIDS TURNING POINT
WORLD BOOK NIGHT AT J’BURG LIBRARY JOHN
8LOCAL BEST BET
LIBRARY TO SHOW ‘HOMES FOR HEROES’ McHENRY – “Homes for Heroes” will be presented from 1 to 2 p.m. Sunday at the McHenry Public Library, 809 N. Front St. To commemorate Veterans Day, the library is showing the film “Homes for Heroes,” narrated by Ron Magers. The film describes the experience of the veterans who have benefited from Transitional Living Services Veterans of McHenry. Alan Belcher, executive director of TLS Veterans of McHenry, will be available after the film to discuss the resources and services available through TLS Veterans McHenry. Veterans from World War II, the Korean War, the Vietnam War, Operation Desert Storm and other conflicts have used in their services and have gone on to find employment, reconnect with their communities and rejoin their families. The program is for those ages 18 and older. Registration may be done in person, online at www. mchenrylibrary.org or by calling 815-385-0036.
Huntley interchange opens State, local officials celebrate completion of project with ribbon-cutting By STEPHEN Di BENEDETTO sdibenedetto@shawmedia.com HUNTbound and westbound interstate traffic, lasted 17 months, but the project’s groundwork began in the late 1990s at the urging of Huntley officials.
News to your phone Text NWHHUNTLEY to 74574 to sign up for HUNTLEY news text alerts from the Northwest Herald. Message and data rates apply. allowed the interchange to be built, Sass said. The Illinois Tollway Authority, Illinois Department of Transportation, McHenry and Kane counties and Huntley all contributed money to the project, which came under budget at $59 million total.
See INTERCHANGE, page B2
Lathan Goumas – lgoumas@shawmedia.com
A Huntley plow truck is one of the first vehicles to use a westbound entry ramp onto Interstate 90 on Friday during a ribbon-cutting ceremony for the Route 47-Interstate 90 interchange.
Home addition OK’d in McHenry
‘We live in the greatest country on Earth’
Size of expansion raised questions By EMILY K. COLEMAN ecoleman@shawmedia.com
Photos by Kyle Grillot – kgrillot@shawmedia.com
ABOVE: Army veteran George Mann (left) pauses during the playing of “Amazing Grace” during the Veterans Day ceremony Friday at McHenry County College in Crystal Lake. The ceremony featured two speakers, veterans Noah Currier and Ryan Blum, as well as patriotic music played by the MCC Concert Band and Chorus. TOP RIGHT: Bagpiper David Cormalleth plays the national anthem at the beginning of the Veterans Day ceremony.
Veterans celebrated at McHenry County College By LAWERENCE SYNETT lsynett@shawmedia.com CRYSTAL Cen-
ter
See VETERANS, page B2
It’s important for people to remember those who made the ultimate sacrifice. It’s nice to be thanked and see a genuine interest in our experiences.” Ryan Blum Army veteran, president of the Military and Student Affairs Association at MCC
McHENRY – A proposed expansion that would quadruple the size of a McHenry home received the goahead from a city committee Thursday evening. The size of the expansion had raised questions on whether it would fit into the surrounding Country Club subdivision, which dates to the early 1920s, but the Teardown Committee voted, 4-1, in favor of the project. Jeff and Jamie Grubich hope to demolish the home at 3208 Golfview Terrace and expand their 2,921-squarefoot home at 3214 Golfview Terrace onto the lot. While the expansion dwarfs the current residence at 7,943 square feet, much of the addition is situated behind the home and not visible from the road. The garage also is placed on an angle to minimize its visual impact from the road. The Grubiches also are requesting three variances, all of which need City Council approval. One request will need to go before the city’s Planning and Zoning Commission as well. “I was comfortable with the way I feel it will blend into the neighborhood,” Alderman Victor Santi said. “It won’t stick out like a sore thumb.” Because the project is in Santi’s ward, he was one of five people to sit on the committee, which by ordinance also includes the chairman of the Planning and Zoning Commission, the chairman of the Landmark Commission, a staff member from the Community
See EXPANSION, page B2
Two developers interested in preserving Huntley mill By STEPHEN Di BENEDETTO sdibenedetto@shawmedia.com HUNTLEY – The village received proposals from two undisclosed developers interested in preserving and redeveloping a historical 19th century mill in downtown Huntley. But Village Manager Dave Johnson said the responses don’t necessarily mean the mill, originally built in the late 1800s, would be redevel-
oped. The Village Board, he said, will have to decide in the coming weeks on the future direction of the building, which local historians have been clamoring to save. “No guarantees,” Johnson said. “The board needs to review and take a look at the proposals. There are many different components to what we see in those proposals, so we are still researching and reviewing, and we will ultimately present it to the Village Board
in the next couple of weeks.” The village has explored redeveloping the mill after officials acquired it last year for $115,000 as part of their ongoing effort to revitalize the look of downtown Huntley. A firm earlier this summer determined that the historical structure needed significant work to bring the building up to code. The village ultimately extended its redevelopment proposal deadline to the end
of October, after only a few developers expressed the desire to invest time and money to preserve the mill. Entering the final week of the extended deadline, the village still had not received a formal proposal, but officials warned at the time that developers typically wait until the last minute to submit ideas. The mill originally belonged to W.G. Sawyer and John Kelley, two local businessmen who were influential
in developing Huntley during the 1800s. After Huntley acquired the structure, local historians immediately lobbied village officials to preserve it upon hearing rumors that the village had plans to demolish the building. Members of the Huntley Historic Preservation Commission have since been meeting with village officials to stay updated on the future direction of the mill.
LOCAL®ION
Page B2 • Saturday, November 9, 2013
Playing 9 holes at Huntley library
Northwest Herald / NWHerald.com
FOX LAKE: TRANSIT PROJECT
Fox Lake receives grant to put development plan into action By EMILY K. COLEMAN ecoleman@shawmedia.com FOX LAKE – The village of Fox Lake received a $3,000 grant from the Regional Transportation Authority to implement its transit-oriented development plan. The grant was one of 10, totaling $360,000, awarded to suburban communities and the Pace suburban bus service. The Regional Transportation Authority will also work with Fox Lake to
ABOVE: Emily Kellas (left), 6, of Huntley and her brothers, Parker, 12, and Liam, 8, watch as their dad putts Friday while attending MiniLinks at the library, hosted by the Huntley Area Public Library District Friends Foundation. Attendees played a nine-hole round of mini golf in the library after hours. LEFT: Brendan Busky, 8, of Algonquin watches his sister putt while attending MiniLinks at the library. Photos by Sarah Nader – snader@shawmedia.com
Veterans speak at MCC event • VETERANS Continued from page B1 Kuwait. Shortly after the 9/11 terrorist attacks, he was sent to Afghanistan crash left the Marine a quadriplegic. Today, Currier is the founder and president of Os-
“It’s kind of an ironic way of getting hurt, but it might have been a blessing in disguise. I was pretty lucky to have even made it home. That’s the way my cards were dealt. I don’t ever look back with regret.” Noah Currier Founder of Oscar Mike, a military apparel company car for one.”
Former historical society administrator concerned with size, casts sole ‘no’ vote • EXPANSION Continued from page B1 Development Department and a member of the public. The sole “no” vote came from Nancy Fike, a resident of the subdivision and former administrator for the McHenry County Historical Society and Museum, who was appointed to the committee after she had gone to the City Council with
“There’s no ordinance on how large a house can be. I couldn’t justify saying it’s too big to be there.” Pat Wirtz Landmark Commission chairman concerns about the project. Although the neighborhood contains a mix of newer homes
several times larger than the cottages that originally made up the subdivision, she thought the proposed home was too big. Despite his vote in favor of the project, Landmark Commission Chairman Pat Wirtz said he thought it also seemed too big for the area. “There’s no ordinance on how large a house can be,” he said. “I couldn’t justify saying it’s too big to be there.”
Craft and Vendor Sale Saturday, November 9 9:00 am - 3:00 pm Cary Park District Community Center 255 Briargate Road, Cary
FREE Admission!
Jaycee Park Holiday Walk Spread holiday cheer and register your group, club, troop, neighborhood, or family and decorate a tree in the holiday walk. Decorated trees will be on display through the holiday season. Register at the Cary Park District. Registration fee applies.
847.639.6100
bring in Urban Land Institute experts to help village staff identify developers and bring them into the downtown area. Fox Lake’s development plan, which was adopted in August by the Village Board, centers around its Metra station. It was paid for using a $100,000 grant from the Regional Transit Authority. The plan suggests streetscape, landscape and facade improvements for the area, in particular the entrances to the village, Route 12 and
Grand Avenue. It recommends adding parking to free up the downtown area. It also gives the village ideas about areas to focus on, including Nippersink Road near Lakefront Park, and suggests possible uses for some of the buildings. The Pace suburban bus service received a $150,000 grant to provide technical assistance as it conducts planning in prospective communities. The goal is to improve local transit options and traffic flow.
New interchange includes six new ramps, reconstructed Route 47 bridge • INTERCHANGE
At a glance: Interchange tolls
Continued from page B1
n Toll rates at the new Route 47-Interstate 90 interchange will be 30 cents to and from the east and 45 cents to and from the west. n Truck rates range from 60 cents to $1.50 to and from the east and 95 cents to $2.50 waved to vehicles from local businesses near the interchange through the new western ramp with black-and-white racing flags. Drivers from Dean Foods, Tom Peck Ford, General RV, Rohrer Corp., LDI Industries, LionHeart Engineering and FYH Bearings honked horns while passing through. The new interchange includes six new ramps and a reconstructured Route
to and from the west in the daytime. Overnight discounts are offered. n Drivers also will need an I-Pass to use the all-electronic interchange.
Source: The Illinois Tollway Authority 47 bridge. The old, eastbound-only interchange at Route 47 and I-90 was constructured in the early 1970s. Huntley officials now will try to capitalize on the full-access interchange and attempt to draw manufacturers and industrial companies to area, as part of an effort to bolster the village’s business sector. The village already has more than 300 acres zoned in the area for commercial and industrial use.
Saturday, November 9, 2013 • Page B3
Northwest Herald / NWHerald.com
November 9 - 10
Welcome to Plan!t Weekend planitnorthwest.com
Top 3 Picks! NOVEMBER 9 & 10 HOLIDAY OPEN HOUSE WEEKEND DOWNTOWN CRYSTAL LAKE Many of the merchants will be offering sneak peaks at new merchandise, gifts and decorating ideas for the home. Come get inspired. Hours vary by stores.
Autumn and PlanitNorthwest.com bring you the most complete listing of events for you and your family each week! Please email Autumn at asiegmeier@shawmedia for the Planit calendar or questions.
Fasten Your Seat Belts
downtowncl.org
1
■ AUTUMN SIEGMEIER, PLANITNORTHWEST.COM
Lately my driving has been a source of controversy at my house. Not so much my actual NOVEMBER 9 & 10 driving but more my practices and procedures “THE NERD” with auto-related things. I have a method, WOODSTOCK OPERA HOUSE, WOODSTOCK like most things in my life, from pumping gas to driving certain routes. Maybe my thought TownSquare Players present this comedy about processes are a bit too quirky for the Golfer in Willum, a Vietnam vet, who has his life all figured My Life, Son and Daughter but the “get in the out until a dinner party he’s hosting goes off the car and go” approach just doesn’t work for me. rails with an unexpected houseguest. Tickets are $23 for adults, $20 for seniors and $13 for stuEver since I got my driver’s license, I have dents. Performance is at 8 p.m. on Saturday and used the same theory for filling my gas tank: 3 p.m. on Sunday. Runs on weekends through I put in as many dollars worth as about my November 24. age. It started in my teens when I could fill up my little Honda for about $10 and has graduwoodstockoperahouse.com ally increased. $20 in my twenties, $30 in my thirties and now about $40. This little trick has served me well. It helps that as the price NOVEMBER 9 HOLIDAY HAPPENINGS CRAFT & VENDOR FAIR of gas has risen I no longer drive an SUV and 1ST UNITED METHODIST CHURCH, MCHENRY have a smaller tank to fill. This also proves my family’s idea that I have been a bit of an overthinker for most of my life! This will include a variety of crafters and home party vendors, bake sale and raffles. A chili Have I mentioned my love of playing the lunch will be available for purchase. License Plate Game on road trips? Keeping From 9 a.m. to 3 p.m. track of all the different states we see represented and marking them down on some odd 815-385-0931 scrap of paper found floating in the car. Just a few months ago, I realized that I play a less formal version of this game all the time. The Golfer and I were leaving the Home Depot and I said “wow, there’s a Kansas.” “Kansas what?” Please note; we try to be as accurate as possible with our events but things are subject “License plate! Do you not look to see where to change without notice. Check the listing and confirm before heading to an event.
2
3
cars are from?” Of course, his answer was no, accompanied by a look I am pretty familiar with by now. The “wow, she is a little crazier than I thought but I shouldn’t be surprised by what I’m hearing” look the Golfer saves for moments just like that. Although he doesn’t play along daily, he’s very supportive when I call him at work to scream in his ear “I’m on Randall Road and I’m behind an ALASKA!” Speaking of Randall Road, we all travel certain routes every day. Some of us select the best one for certain times of the day, strategically choose lanes and avoid stoplights when possible; others just drive. When I explained this to the Golfer, he shook his head. But we have made many extra trips around the block when he has pulled out the driveway and headed the wrong direction. “How do I ever make from Point A to Point B without you in the car?” the Golfer has sarcastically asked a few times. My thoughts exactly! Quick review: We kept the weekly movie date night going and saw “Rush,” the Ron Howard film about Formula One drivers in the 1970s. The Golfer gave it a Birdie on a Par 5 and I enjoyed it more than I thought I would. Interesting sports story (even the Golfer didn’t know it!) and I must say Chris Hemsworth can work that shaggy ‘70s look. “12 Years a Slave” is penciled in for Tuesday since it has finally opened at theaters out here. Enjoy the weekend! Autumn
Spotlight!
Regional Event! NOVEMBER 10 WHAT ROGER EBERT MEANT TO US HAMMERSCHIMDT CHAPEL AT ELMHURST COLLEGE, ELMHURST
Glo-Bowl Fun Center
This panel. Tickets are $20 each. Starts at 7 p.m. public.elmhurst.edu for ticket
101 FRANKS ROAD MARENGO 815-658-3425
What is Plan!t?
The Glo-Bowl Fun Center in Marengo is where the fun never ends! Features 16 Brunswick bowling lanes with a state-of-the-art scoring system. Cosmic Bowling is available Friday and Saturday evenings as well as early afternoon on the weekends. Reservations are strongly recommended. Open seven days a week. PlanitNorthwest.com organizes everything you need for affordable weekend fun! With our money saving vouchers and extensive events calendar you can always find something to do on Planit!
Planit is where you will find: The best local deals and coupons for the businesses you visit save on shopping, dining and entertainment! Our calendar with the best list of family friendly events and activities. All the details for local festivals, concerts and more!
Just North of Ashley Furniture and The Great Escape
Mon - Fri: 11:00 am - 7:00 pm Sat: 11:00 am - 5:00 pm Sun: 12:00 pm - 5:00 pm
Check Us Out On
Bicycle Sales And Service Join The Republic
Buy a 1# of Bulk Coffee and Get 2-1oz. Packets of Loose Leaf Tea
FREE Up to a $6.00 value
planitnorthwest.com
2397 S. Randall Rd. • Algonuin, IL • (224) 699-9589
Buddha Bean ~ 77 W. Main St. Cary, IL
Elite Kids’ Academic Preschool For the child who knows what she’s looking for! • Reading • Art • Gymnastics • Writing • Science • Dance • Math • Social Studies • Swimming
Elite Kids 825 Munshaw Lane, Suite B. Crystal Lake, IL. 60014 (815) 451-9600 Elite Kids is a licensed Preschool Program through the State of Illinois. License # 517209-02
• Violin • Spanish
1345 S. Eastwood Dr. • Woodstock Hours: M-W 9-5, Thurs 9-7, Fri & Sat 9-5, Sun 12-4
815-338-1086
Page B4 • Saturday, November 9, 2013
LOCAL®ION
Northwest Herald / NWHerald.com
8BLOOD DRIVES
GENEVA: DEMOCRATIC NOMINATION
Hosta declares for 14th congressional race By BRENDA SCHORY bschory@shawmedia.com GENEVA – A second hopeful – John J. Hosta of Spring Grove – has announced he will seek the Democratic nomination in the March 18 primary for the 14th Congressional District, the seat currently held by U.S. Rep. Randy Hultgren, R-Winfield. Hosta, 55, a small-business owner who makes custom bedding for interior designers, said he will kick off his campaign at 7 p.m. Nov. 22 in the Kane County Government Center, Building A, 719 S. Batavia Ave., Geneva. “I’m a conservative Demo-
crat,” Hosta said. In deciding this platform for seeking office, Hosta said he compiled a list of what he thinks is important and also vital to people in the district. “ I feel I am not a hard-right liner and not hard liberal,” Hosta said. “I’m John J. Hosta a moderate.” His platform is to bring industry back to the United States with tax incentives. Hosta said the nation has lost 30 percent of its manufacturing jobs, directly related to imports in the past 12 years. “I believe that the Found-
ing Fathers of our country were dedicated to U.S. companies, protecting U.S. industries through tariffs,” Hosta said. “Since World War II, we have fallen away from that. Companies seek what is most profitable for them and move abroad. ... I think that is very anti-American. The cry of the American people is for them to be faithful to this country and bring industries back.” Hosta also supports protections for Social Security and welfare, and said unemployment and food stamp programs need to be reviewed and strengthened – not cut. “The elderly are scared, extremely concerned that ben-
District 15 school board When: 7:30 p.m. Tuesday Where: Landmark Elementary School, 3614 W. Waukegan Road, McHenry
When: 6:30 p.m. Tuesday Where: Fox Lake Village Board, 66 Thillen Drive
efits will be cut or have to be cut,” Hosta said. “And people on disability – you can’t just turn your back on them. As a society, we are obligated to these people.” Hosta is the second Democrat to declare for the primary, following Dennis Anderson of Gurnee. Anderson lost to incumbent Hultgren last year but announced in August that he would seek the Democratic nomination again. Hultgren announced in September his intention to seek re-election. The 14th District includes seven suburban counties – Kane, DuPage, DeKalb, Will, McHenry, Lake and Kendall.
8PUBLIC ACCESS MONDAY District 300 school board When: 7:30 p.m. Monday Where: Westfield Community School, 2100 Sleepy Hollow Road, Algonquin Marengo City Council When: 7 p.m. Monday Where: Marengo City Hall, 132 E. Prairie St. Johnsburg Ordinance Committee When: 7 p.m. Monday Where: Village Hall, 1515 Channel Beach Ave. The Monday meeting of the McHenry County Board Management Services Committee has been canceled.
TUESDAY
OBITUARIES ALICE MARY BURKE The Mass of Christian Burial for Alice Mary Burke (nee Weimer), age 93, will be held at 10:00 a.m., Tuesday, November 12, 2013, at St. Anne Church, 120 N. Ela St. (not Ela Road), Barrington, where there will be visitation from 9:00 a.m. until the time of Mass. The celebrant will be Father Tom Bishop. Burial will be in Evergreen Cemetery, Barrington. There will also be a visitation Monday, November 11, 2013 from 3:00-8:00 p.m., at the Davenport Family Funeral Home, 149 W. Main St. (Lake-Cook Road), Barrington. Born January 13, 1920, in Chicago, to the late George and Anne Weimer, Alice passed away Thursday, November 7, 2013, at JourneyCare Hospice Home, Barrington. Formerly of Oak Park, Alice and her family moved to Barrington in 1968. She lived at Lake Barrington Woods Retirement Center for the past 13 years. She was an avid Bears, Cubs, and Blackhawks fan, rarely missing a game. She will be dearly missed by her family and friends. Alice was a long-time member of St. Anne Women's Club, where she began friendships that lasted 45 years. Her wonderful friends at “Rent a Crowd” were very dear to her. Alice was the loving mother of David (Jeannie) Burke, Patricia (Jack) Baker, Jeannie (Greg) Kerkera, and Daniel Burke; devoted grandmother of Sarah and Allie, Scott, Chris and Tom, and Carolyn, Mike, and Kyle; dear great-grandmother of Cameron, Gavin, and Fiona, Tyler, Ellie, and Katie, and Owen; and fond sister-in-law of William and Lorraine Burke. She was preceded in death by her husband, Edmund; and sister, Dorothy Shepherd. In lieu of flowers, memorials in Alice's name may be made to JourneyCare Foundation, 405 Lake Zurich Rd., Barrington, IL 60010,. You may leave online condolences for the family at, or call 847-381-3411, for information.
BOLESTAW 'BILL' URBANSKI Bolestaw “Bill” Urbanski, age 88, entered into his new life on November 6, 2013 with his loving family at his side. Born August 27, 1925 in Bayonne, New Jersey, Bill proudly served his country with the Navy in WWII as well as the Korean War. Following
District 46 school board When: 7 p.m. Tuesday Where: Prairie Grove Junior High School library, 3225 Route 176, Crystal Lake District 165 school board When: 6 p.m. Tuesday Where: Superintendent Office, 816 E. Grant Highway, Marengo District 200 school board When: 7 p.m. Tuesday Where: Clay Professional Development Center, 112 Grove St., Woodstock Fox Lake Village Board
The Harvard City Council meeting scheduled for 7 p.m. Tuesday, has been canceled.
McHenry Community Development Committee When: 7 p.m. Tuesday Where: Aldermen’s Conference Room, McHenry Municipal Center, 333 S. Green St.
Johnsburg Community Affairs Committee When: 7 p.m. Tuesday Where: Village Hall, 1515 Channel Beach Ave.
Spring Grove Economic and Development Commission When: 6:30 p.m. Tuesday Where: Spring Grove Village Hall, 7401 Meyer Road
Lake in the Hills Committee of the Whole When: 7:30 p.m. Tuesday Where: Village Hall, 600 Harvest
Volo Village Board When: 7:30 p.m. Tuesday Where: Volo Village Hall, 500 S. Fish Lake Road
GEORGE P. LAYOFF
Doloris JoAnn Maynard, age 78, of Fontana, Wisconsin, died Thursday, November 7, 2013 at Williams Bay Care Center. She was born April 14, 1935 in Poplar Grove, Illinois to Clarence and Jennie (Loudenbeck) Peters. Doloris was a homemaker and had been a school bus driver for special education district in McHenry County, Illinois and in Walworth County, Wisconsin. She was a member of Trinity Lutheran Church in Harvard. Doloris was a very loving person and was loved by all. Survivors include her husband, Charles “Charlie” William Maynard of Fontana, whom she married December 18, 1971 in Harvard; children, Terry (Lydia) Donner of Hartford, Wisconsin, Larry (Noreen) Donner of Walworth, William (Sara)
McCullom Lake Village Board When: 7 p.m. Tuesday Where: McCullom Lake Village Board, 4811 W. Orchard Drive
Johnsburg Planning and Zoning Commission When: 7 p.m. Tuesday Where: Village Hall, 1515 Channel Beach Ave.
rth, W (Sara) Maynard of Beloit, Wisconsin; stepchildren, John (Sarah) Maynard of How to submit Harvard, and Michelle (William) Evans of Friedrickstown, Missouri; Send information to obits@ a granddaughter, JoAnn Donner of nwherald.com or call 815-526-4438. Brown Deer, Wisconsin; step-grandNotices are accepted until 3pm for children, Donald Webb, Keeley and the next day’s paper. Logan Yancey, William, Nicole, and Elizabeth Evans, and Randy (Teresa) Obituaries also appear online at Welch; great-grandson, Drew nwherald.com/obits where you may Warichak; step-great-grandchildren, Brian and Ally Welch; brother sign the guestbook, send flowers or Arwayne (Marilyn) Peters of Kansas make a memorial donation. City, Missouri; brother and sister-inlaw, Ralph and Helen Maynard of ng Poplar Grove; brother-in-law, his active duty, Bill was a civilian Richard Young of Sun City Center, Navy contractor for 30 years. Next Florida. to being a loving father, grandfaShe was preceded in death by ther, and great-grandfather, he en- her parents, first husband, Harry joyed outdoor activities to include Donner, Jr; sister, Norma Young; hunting, fishing and camping. brother, Lewayne Peters; stepBill will be dearly missed by his daughter, Tammy Maynard; and two loving daughters, Debra (Leo) sister-in-law, Margaret Peters. Velez, and Linda (Dave) Evins; The visitation will be from 4:00 to three grandchildren, Jason (Sara) 7:00 pm Monday, November 11, Velez, William (Diana) Manley, and 2013 at Saunders & McFarlin FunerChristina Velez; two great-grandal Home, 107 W. Sumner St., Harchildren, Santiago and Joaquin vard. The funeral will be 11:00 am Velez. Tuesday, November 12, 2013 at the He was preceded in death by funeral home with Rev. Herb his parents, Bolestaw and Mary Priester officiating. Interment will Urbanski, and his loving sisters, be in Mt. Auburn Cemetery in Janet (Jack) McKenzie and Jean (Al) Harvard. Smith. Memorials may be made to Trinity A memorial visitation for Bolestaw Lutheran Church, 504 E. Diggins St., will be held Saturday, November 9, Harvard, IL 60033. 2013 from 12:00 p.m. until the time Sign the online guest book at of service at 1:00 p.m. at Davenport saundersmcfarlin.net Family Funeral Home, 419 E. Terra Cotta Ave, Crystal Lake, IL 60014. In lieu of flowers, memorial donaELEANOR L. 'PENNY' tions may be made to the JourneyCare Foundation, 405 Lake Zurich SENKE Rd, Barrington, IL 60010. To leave online condolences, Eleanor L. “Penny” Senke, age 91, please visit of McHenry, passed away Friday November 8, 2013 at Heritage or call the funeral home at Woods of McHenry. 815-459-3411 for information. Arrangements pending at Colonial Funeral Home Mchenry for info call 815-385-0063
DOLORIS MAYNARD
Gate
George P. Layoff, age 75, of McHenry, passed away November 6, 2013, at Centegra HospitalMcHenry.
utcher B ON THE BLOCK USDA Choice
MEAT & DELI LAKE IN THE HILLS, IL
4660 W. Algonquin Rd., Lake in the Hills, IL 60156
847-669-6679 butcher@butcherontheblock.com Hours: 9–6 Mon.–Sat. • 10–4 Sun. Specialty Meats • Deli • Beef • Pork Chicken • Lamb • Veal • Seafood Roasts • Ribs • Sandwiches • Party Trays
He was born October 24, 1938 in Bellville, to Redginald and Annette (Corydon) Layoff. On August 27, 1962 he married Gloria Brumfield in Wooddale. George was a trucker for 35 years, having worked for Terra Cotta Trucking in Crystal Lake. He was a member of Teamsters Union Local 301. George enjoyed crosswords, handheld poker, and watching the Packers. Most of all he loved driving, whether it was for work or on vacations with his family. He is survived by his wife, Gloria; his children, George (Christine) Layoff and Diana Layoff; his grandchildren, Gerret and Josiah Layoff; his siblings, Jackie Shara and Redginald “Bud” (Jan) Layoff; and many extended family members. He was preceded in death by his parents and his siblings, Dorothy Kaminski and William “Bill” Layoff. Visitation will be from 4:00 to 8:00pm on Sunday, November 10, 2013 at Querhammer & Flagg Funeral Home, 500 W. Terra Cotta Ave., Crystal Lake. The funeral service will be at 11:00am on Monday, November 11, 2013 at the funeral home. Interment will be in McHenry County Memorial Park, Woodstock. Memorials may be made to Pioneer Center, Bridges Program, 4001 Dayton Street, McHenry, IL 60050. For information, call the funeral home at 815-459-1760. Online condolences may be made at
LOVIE L. JONES Lovie L. Jones, age 75, of McHenry, died Thursday, November 13, 2013, at Advocate Condell Medical Center. Funeral arrangements are pending at Justen Funeral Home & Crematory, 3700 W. Charles J. Miller Road, McHenry. A complete notice will run in the Sunday edition of the Northwest Herald. For information, call 815-385-2400, or visit.
Special Discount utcher
B ON THE BLOCK USDA Choice
1 Bone-In Pork Chop (8oz. Avg.)......................... $1.00 1 lb Stew Meat.................. $2.00 1 lb Ground Chuck.............. $2.00 1 lb Ground Turkey..............$2.00 1 Boneless Chicken Cutlet... $1.00 1 Bratwurst....................... $1.00 (1) 1/4 lb All Beef Hot Dog...$1.00 Limit one coupon per customer. Must present coupon at time of purchase. Expires November 17, 2013.
Following is a list of places to give blood. Donors should be 17 or older or 16 with a parent’s consent, weigh at least 110 pounds, and be in good health. • 8 a.m. to noon Saturday – St. Elizabeth Ann Seton Church, 1023 McHenry Ave., Crystal Lake. All donors receive a Culver’s coupon. Walk-ins welcome. Appointments and information: Joe Moceri, 815-970-4357 or www. heartlandbc.org. • 9 a.m. to 1 p.m. Saturday – St. Patrick’s Catholic Church, 3500 W. Washington St., McHenry. All donors receive a Culver’s coupon. Walk-ins welcome. Appointments and information: Bobbie Girard, 815-385-4329 or. • 11:30 a.m. to 3:30 p.m. Monday – Walmart, 1205 S. Route 31, Crystal Lake. All donors receive a T-shirt honoring our veterans. Appointments and information:. • 3 to 7 p.m. Tuesday – City of Woodstock Recreation Department, 820 Lake Ave., Woodstock. All donors receive a Guns & Hoses T-shirt. Walk-ins welcome. Appointments and information: 815-338-4363 or. • 3 to 7 p.m. Thursday – City of Crystal Lake, 100 W. Municipal Complex, Crystal Lake. All donors receive a Centennial T-shirt. Walk-ins welcome. Appointments and information:
Roxie, 815-477-0086 or www. heartlandbc.org. • 8:30 to 11:30 a.m. Nov. 16 – McHenry VFW Post 4600, 3002 W. Route 120, McHenry. All donors receive a T-shirt in honor of our veterans. Walk-ins welcome. Appointments and information: 815-385-4600 or. • 8 a.m. to noon Nov. 17 – Marengo United Methodist Church, 119 E. Washington St., Marengo. Walk-ins welcome. Appointments and information: 815-568-7162. • 9 a.m. to 2 p.m. Nov. 19 – Woodstock North High School, 3000 Raffel Road, Woodstock. All donors receive gray flannel lounge pants. Walk-ins welcome. Appointments and information:. • 4 to 7 p.m. Nov. 21 – Huntley Public Library, 11000 Ruth Road, Huntley. Walk-ins welcome. Appointments and information: 847-669-5386, ext. 21. • 3:30 to 7:30 p.m. Nov. 25 – Joyful Harvest Lutheran Church, 5050 N. Johnsburg Road, Johnsburg. All donors receive a Culver’s coupon. Walkins welcome. Appointments and information: 847-497-4569 or. • 3:30 to 6:30 p.m. Nov. 26 – Richmond Fire Department, 5601 Hunter Drive, Richmond. Walk-ins welcome. Appointments and information: 815-6783672 or.
8POLICE REPORTS Huntley • A 17-year-old Huntley girl was charged Friday, Oct. 25, with theft, drug paraphernalia possession and underage tobacco possession. • Joshua J. Alejandro, 18, 11003
Bonnie Brae Road, Huntley, was charged Sunday, Oct. 27, with marijuana possession. • Bonnie L. Borchardt, 45, 11611 E. Main St., Huntley, was charged Sunday, Oct. 27, with two counts of domestic battery.
WILLIAM J. SUCHOR
8FUNERAL ARRANGEMENTS
William J. Suchor, age 81, of Island Lake, died Sunday, October 20, 2013 at his home in Island Lake. He was born June 17, 1932 in Cicero to Joseph and Verna (Ostrowski) Suchor. William was a longtime resident of Island Lake. He was employed over 40 years in the printing industry and a member of the Graphic Commercial International Union Local 458. He was a veteran of the U.S. Navy from March 11, 1952 until March 10, 1960 and served in the Korean War. In his early years, William loved to go boating and sailing. He was an avid snowmobile enthusiast during the week when new snowfall occurred and the trails were fresh. He also enjoyed fishing, playing cards, cutting the grass and maintaining his home. Spending time with family and friends meant a great deal to him. Survivors include two sons, David (Leslie) Suchor of Island Lake, Steven Suchor of Island Lake; his former daughter-in-law, Ann Stauche of McHenry; six grandchildren, Ryan, Dylan, Samantha, Casey, Elizabeth and Lucas; and sister-inlaws, Irene Suchor of McHenry, Betty Clavey of Mt. Prospect and Mary Lou Slove of Wauconda. He was preceded in death by his wife, Patricia (Lipinski) Suchor on March 10, 2011; his parents; his brother, Ronald; and a sister-in-law, Alice Pleszewa. A memorial service will be held for Bill and Pat on Sunday, November 17, 2013 from 1:00 p.m. until 5:00 p.m. at the Lake Zurich American Legion, 51 Lions Drive, Lake Zurich, IL. Arrangements entrusted to Justen Funeral Home & Crematory, McHenry, IL. For information, please call the funeral home at 815-385-2400, or visit.
Herman F. Kunde: The visitation will be from 9 to 11 a.m. Saturday, Nov. 9, at Zion Lutheran Church, 412 Jackson St., Marengo. The service will be at 11 a.m. Interment will be in Marengo City Cemetery. George P. Layoff: The visitation will be from 4 to 8 p.m. Sunday, Nov. 10, at Querhammer & Flagg Funeral Home, 500 W. Terra Cotta Ave., Crystal Lake. The funeral service will be at 11 a.m. Monday, Nov. 11, at the funeral home. Interment will be in McHenry County Memorial Park, Woodstock. Emma M. Meyer: The visitation will be from 10 to 11:45 a.m. Saturday, Nov. 9, at Kahle-Moore Funeral Home, 403 Silver Road, Cary. The funeral service will be at noon Saturday, Nov. 9, at Holy Lutheran Church, 2107 Three Oaks Road, Cary. Burial will be in Windridge Memorial Park. For information, call the funeral home at 847-639-3817. Barbara Ann Gengler O’Rourke: The memorial service will be at 10 a.m. Saturday, Nov. 9, at the Church of Holy Apostles, 5211 Bull Valley Road, McHenry. Private family burial will be in Mount Calvary Cemetery in Dubuque, Iowa at a later date. Friends may call from 10 to 11 a.m. Saturday, Nov. 9, with a funeral Mass celebration at 11 a.m. Bolestaw “Bill” Urbanski: A memorial visitation for Bolestaw will be Saturday, Nov. 9, from noon until the service at 1 p.m. at Davenport Family Funeral Home, 419 E. Terra Cotta Ave., Crystal Lake.
WHAT CAN
THE BEE DO FOR
YOU?
10%off Carpet Cleaning
815-893-8155 Valid on any service of $115.00 or more. Cannot be combined with any other offer. Expires Nov. 30, 2013.
Clean Bee Flooring & Upholstry Care
815-893-8155 w w w. c l e a n b e e. n e t
QUICKCRITIC
More reviews at PlanitNorthwest.com Saturday, November 9, 2013 • Page B5
REVIEWS & LOCAL SHOWTIMES OF NEW MOVIES
LOCAL SHOWTIMES
ON SCREEN NOW RATED: PG-13 for some violence, sci-fi
“Captain Phillips” STARRING: Tom Hanks, Barkhad Abdi, Barkhad Abdirahman PLOT: This is the true story of Captain Richard Phillips and the 2009 hijacking by Somali pirates of the U.S.flagged MV Maersk Alabama, the first American cargo ship to be hijacked in 200 years. RATED: PG-13 for sustained intense sequences of menace, some violence with bloody images and substance use TIME: 2 hours, 14 minutes VERDICT: If you saw Paul Greengrass’ . Tom. Things get even more intense in the lifeboat, where the pirates are locked in with Phillips for several agonizing days. With the U.S. Navy bearing down, it’s pretty clear where it’s all headed. The only question: Who will die? – The
action and thematic material TIME: 1 hour, 54 minutes VERDICT: An anti-bullying allegory writ on the largest possible scale, “Ender’s Game” frames an interstellar battle between mankind and pushy antlike. Although among the various squad members. – Variety
Associated Press
“Last Vegas”
“Ender’s Game” STARRING: Harrison Ford, Asa Butterfield, Hailee Steinfeld, Abigail Breslin
PLOT: The International Military seeks out a leader who can save the human race from an alien attack. Ender Wiggin, a brilliant young mind, is recruited and trained to lead his fellow soldiers into a battle that will determine the future of Earth.
STARRING: Robert De Niro, Michael Douglas, Morgan Freeman, Kevin Kline PLOT: Three sixty-something friends take a break from their day-to-day lives to throw a bachelor party in Las Vegas for their last remaining single pal. RATED: PG-13 on appeal for sexual content and language
TIME: 1 hour, 45 minutes VERDICT:, although a smattering of funny gags and the nostalgia value of the cast keeps the whole thing more watchable than it has any right todried,, although), also is . The rest of the movie rarely if ever rises to Steenburgen’s level.
“Thor: The Dark World” STARRING: Chris Hemsworth, Natalie Portman, Tom Hiddleston
PLOT: Thor, faced with an enemy even Odin and Asgard cannot withstand, must embark on his most perilous and personal journey yet, one that will reunite him with Jane Foster and force him to sacrifice everything to save us all. RATED: PG-13 for sequences of intense sci-fi action and violence, and some suggestive content TIME: 1 hour, 51 minutes
VERDICT:. Ardent fans (who should stay through the credits) will likely be satiated by the pleasing enough “Thor: The Dark World.” But perhaps at this point, even diehards may wish for something more from a Marvel equation that often subtracts humanity.
“ABOUT TIME”
“GRAVITY”
AMC Lake in the Hills 12 – 10:40 a.m., 1:35, 4:25, 7:15, 10:40 p.m. Regal Cinemas – 10:10 a.m., 1:10, 4:10, 7:10, 10:10, 11:40 p.m.
AMC Lake in the Hills 12 – 2D: 5:15, 10:15 p.m.; 3D: 10:10 a.m., 12:25, 2:45, 7:25, 11:55 p.m. Classic Cinemas Carpentersville – 12:20, 2:30, 4:40, 6:50, 9:00 p.m. Classic Cinemas Woodstock – 4:50, 7:00, 9:10 p.m. Regal Cinemas – 2D: 1:40 p.m.; 3D: 11:10 a.m., 4:20, 6:50, 9:20 p.m.
“CAPTAIN PHILLIPS” AMC Lake in the Hills 12 – 11:00 a.m., 2:00, 5:05, 8:05, 11:05 p.m. Classic Cinemas Carpentersville – 1:10, 4:00, 6:50, 9:40 p.m. Regal Cinemas – 11:50 a.m., 3:30, 7:15, 10:25 p.m.
“CARRIE” Classic Cinemas Carpentersville – 12:30, 2:45, 5:00, 7:15, 9:30 p.m. Regal Cinemas – 12:00, 2:40, 5:30, 8:10, 10:50 p.m.
“CLOUDY WITH A CHANCE OF MEATBALLS 2” Classic Cinemas Carpentersville – 12:10, 2:20, 4:30, 6:40 p.m. Regal Cinemas – 10:05 a.m., 12:40, 3:10, 6:10, 8:50 p.m.
“THE COUNSELOR” AMC Lake in the Hills 12 – 10:55 a.m.
“ENDER’S GAME” AMC Lake in the Hills 12 – 10:05 a.m., 12:45, 1:45, 3:25, 4:35, 6:05, 7:20, 8:45, 10:00, 11:35 p.m. Classic Cinemas Carpentersville – 12:00, 2:25, 4:50, 7:20, 9:50 p.m. Classic Cinemas Woodstock – 4:50, 7:20, 9:50 p.m. Regal Cinemas – 12:10, 3:40, 7:50, 10:45, 11:15 p.m.
“ESCAPE PLAN” Classic Cinemas Carpentersville – 1:45, 4:35, 7:10, 9:45 p.m.
“FREE BIRDS” AMC Lake in the Hills 12 – 2D: 10:00 a.m., 12:45, 3:00, 7:30 p.m.; 3D: 5:10, 9:40 p.m. Classic Cinemas Carpentersville – 2D: 11:00 a.m., 12:00, 1:00, 3:10, 4:20, 5:20, 7:30, 8:40, 9:40 p.m.; 3D: 2:10, 6:30 p.m. Classic Cinemas Woodstock – 2D: 6:30 p.m.; 3D: 4:20, 8:40 p.m. McHenry Downtown Theatre – 1:00, 3:30, 6:15, 8:30 p.m. Regal Cinemas – 2D: 10:40 a.m., 1:20, 3:50, 6:40, 9:10 p.m.; 3D: 11:30 a.m., 2:10, 4:40, 7:30 p.m.
“JACKASS PRESENTS: BAD GRANDPA” AMC Lake in the Hills 12 – 11:25 a.m., 1:50, 4:10, 6:40, 9:45 p.m., 12:05 a.m. Classic Cinemas Carpentersville – 1:00, 3:10, 5:20, 7:30, 9:40 p.m. Classic Cinemas Woodstock – 5:10, 7:20, 9:30 p.m. Regal Cinemas – 10:20, 11:25 a.m., 12:50, 2:15, 3:20, 4:50, 6:00, 7:25, 8:40, 10:35, 11:30 p.m.
“LAST VEGAS” AMC Lake in the Hills 12 – 10:50 a.m., 1:25, 3:55, 6:25, 8:55 p.m., 12:00 a.m. Classic Cinemas Carpentersville – 12:00, 2:20, 4:40, 7:00, 9:20 p.m. Regal Cinemas – 11:20 a.m., 12:20, 2:20, 3:00, 5:20, 7:20, 8:00, 10:20, 11:00 p.m.
“RUSH” Regal Cinemas – 10:05 p.m.
“THOR: THE DARK WORLD” AMC Lake in the Hills 12 – 11:30 a.m., 1:30, 2:15, 5:00, 7:00, 8:45, 9:45, 11:30 p.m.; 3D: 10:00, 10:45 a.m., 12:30, 3:15, 4:15, 6:00, 7:45, 10:45 p.m. Classic Cinemas Carpentersville – 2D: 11:00 a.m., 1:30, 4:00, 6:30, 9:00 p.m.; 3D: 12:00, 2:30, 5:00, 7:30, 10:00 p.m. Classic Cinemas Woodstock – 2D: 4:00, 6:30, 9:00 p.m.; 3D: 5:00, 7:30, 10:00 p.m. McHenry Downtown Theatre – 1:15, 4:00, 6:45, 9:00 p.m. Regal Cinemas – 2D: 10:00, 11:00 a.m., 1:00, 2:00, 4:00, 5:00, 7:00, 8:20, 10:00 p.m.; 3D: 10:30 a.m., 1:30, 4:30, 7:40, 10:40, 11:20 p.m., 12:01 a.m.
“12 YEARS A SLAVE” AMC Lake in the Hills 12 – 10:30 a.m., 1:40, 4:40, 7:40, 9:00, 11:25 p.m.
– The Associated Press
37th Annual Fall Anniversary Sale! Saving s Up To 50%!
Voted One of the Best Hotels In McHenry County
Solid Wood Furniture Made in the USA
600 Tracy Trail Crystal Lake, IL 60014 815-477-3500 1-800-456-4000
Mention this ad Get
15% OFF
Offer good now thru November 30, 2013. Not valid with any other offer. Based on availability.
Hurry! Sale Ends November 17th
Strode’s furniture
Your Hometown Store Since 1976! FREE DELIVERY Interest Free Financing Available
11707 E. MAIN ST., HUNTLEY Monday - Saturday847-669-3500 9-5, Thursday 9-9 s r
r
Open Sundays 12-5 1st-17th Monday - Saturday 9-5,Thursday 9-9,Now. Closed Sunday
LOCAL®ION
Page B6 • Saturday, November 9, 2013
Northwest Herald / NWHerald.com
Independent woman sets bar Prevent flat spots on baby’s high in search for Mr. Right head by varying his position you need to continue looking for someone who is as independent as you are, so you can find an
DEAR ABBY Jeanne Phillips attractive man whose needs are similar to yours. Some couples find the process of dating a smooth and easy one. For others it’s complicated, but not impossible. I agree he was exposed. The restaurant was full, so I couldn’t request another table. – Lost
My Appetite In Myrtle Beach, S.C. Dear Lost.”
In Crofton, Md. Dear Nobody’s Therapist: Try this: Say, “Really, I’m sorry to hear that.” Then change the
• Write Dear Abby at www. dearabby.com or P.O. Box 69440, Los Angeles, CA 90069.
Caring Family,SC
Todd S Giese, MD George B Gancayco, MD Racquel N Ramirez, MD Jamie TM Gancayco, MD
Celebrating 25 years of caring faith based private practice doctors you can trust
Board Certified Medical Care for the Whole Family since 1988 815-459-2200 by appointment 815-459-220 0 learn more on our web site at
Text the corresponding Keyword to 74574 to start receiving news from these towns: Local News
• Algonquin – Keyword: NWHALGONQUIN • Cary – Keyword: NWHCARY • Crystal Lake – Keyword: NWHCRYSTALLAKE • Fox River Grove – Keyword: NWHFOXRIVERGROVE • Harvard – Keyword: NWHHARVARD • Hebron – Keyword: NWHHEBRON • Huntley – Keyword: NWHHUNTLEY • Johnsburg – Keyword: NWHJOHNSBURG • Lake in the Hills – Keyword: NWHLITH • Marengo – Keyword: NWHMARENGO • McHenry – Keyword: NWHMCHENRY • Richmond – Keyword: NWHRICHMOND • Woodstock – Keyword: NWHWOODSTOCK Scan to select from a menu of options
Area News and Weather
• Breaking News – Keyword: NWHNEWS • Daily Forecast – Keyword: NWHWEATHER Message and data rates apply.
Dear Dr. during infancy. It also makes their skulls sensitive to pressure, especially when that pressure is always in the same place. Flat spots don’t cause brain damage or affect brain function. They can, however,
ASK DR. K Dr. Anthony Komaroff lead to teasing if the shape is very abnormal. To prevent flat spots, change the position of your baby’s head throughout the day: • Give your baby “tummy time” when he is awake and being watched. Do this for at least a few.
• Write to Dr. Komaroff at or Ask Doctor K, 10 Shattuck St., Second Floor, Boston, MA 02115.
COMICS
Northwest Herald / NWHerald.com
Pickles
Brian Crane Pearls Before Swine
For Better or For Worse
Non Sequitur
Saturday, November 9, 2013 • Page B7 & Greg Walker
Jimmy Johnson
Lincoln Pierce
Jan Eliot
Bill Schorr
Wife: Chef was treated for aneurysm
THINGS
The wife of Charlie Trotter said doctors discovered the acclaimed chef had an aneurysm months before he died and he’d been taking medicine to control seizures, his blood pressure and high cholesterol. Trotter, Rochelle Trotter said the aneurysm was discovered in January and doctors had prescribed the “proper medication.”
WORTH TALKIN’ ABOUT
Friday, November 9, 2013 • Section B • Page 8
BUZZWORTHY
NBC gets commercial space trip coverage.
‘Star Trek’ actress to pen memoir.”
Morissette album headed to stage.
Eminem’s childhood home catches fire.
Print edition of The Onion to end.”
TODAY’S BIRTHDAYS.
p O e d n n i n a g! r G Custom made. Comfortably priced.™
~ 30 YEARS EXPERIENCE ~
• Carpet Rolls In Stock At
MORE THAN 20 MODELS TO CHOOSE FROM! SAVE UP TO RS WOm_ZMZRSmY mattress sets
$
100
INTRODUCTORY NMmOMZS\ mM
TWIN $
169
on Classical mattress sets
150
SAVE UPTO
$
FIRM
RS cY^\mSM mattress sets
200
$
PLUSH
NMmOMZS\ mM
TWIN $
229
NMmOMZS\ mM
TWIN
$
269
FULL
QUEEN
FULL
QUEEN
KING
FULL
QUEEN
KING
$229
$249
$319
$349
$499
$369
$399
$599
EUROTOP NMmOMZS\ mM
SAVE UPTO
TWIN $
299
TWIN $
349
FULL
QUEEN
KING
FULL
QUEEN
KING
$399
$449
$649
$449
$499
$749
JYY nmkN mO^ `RYROeTmM`[ RO TZSRO ]mlOZ` nmkN RSYjV JYY l^_N mO^ [mS_`Om]M^_ kZM[ RLO LNLmY [Z\[ePLmYZMj ZSS^ONQOZS\ LSZMNf QO^e`RTe QO^NN^_ `RMMRS mS_ LQ[RYNM^Oje\Om_^ ]RmTd iX^^ NMRO^ ]RO _^MmZYNh
SAVINGS EXPIRE ""/"!/13!
Blowout Prices For Immediate Install
• Unbelievable Selections for all types of flooring
• Professional Installations
TAKE AN EXTRA 10% OFF Hardwood • Bamboo • Carpet Luxury Vinyl Tile • Ceramic
PILLOWTOP NMmOMZS\ mM
Keith and Natalie Murphy have ventured out to bring you Murphy’s Flooring, a family-owned business providing excellent customer service and professional installation. For over twenty-five years, Keith has serviced McHenry County homeowners and businesses with their flooring needs. Taking pride in our vast knowledge of products and installation techniques; our vision was to develop a showroom of flooring products to fit everyone’s needs.
W[ Ma ^ aZNT ttr m `[m ess Sale M`[ S`^ i MR ` s our out Y o ^ mO mS_ verst `RK _ZN`R ock LS ^ CHA ONf mS_ M^_ YO NCE BIG TO G UR SAV ING ET S!
~ Financing Available ~
★
gUZM[ bm`MROj aZNTmM`[ `RK^ONd X^^ NMRO^ ]RO _^MmZYNd
McHENRY
LAKE GENEVA
CRYSTAL LAKE
3710 W Elm Street McHenry, IL 60050
2462 Hwy 120 Lake Geneva, WI 53147
5150 NW Hwy, Unit 1 Crystal Lake, IL 60014
815-578-8375
262-249-0420
815-455-2570
facebook.com/verlomattress
twitter.com/verlostores
youtube.com/verlomattress
2104 S. Eastwood Drive • Woodstock, IL
815-334-5985 Hours: Mon–Thurs 10–6, Fri. 10–5, Sat 10–4
Sports
SECTION C Saturday, November 9, 2013 Northwest Herald
Breaking news @
Sports editor: Jon Styf • jstyf@shawmedia.com
FOX VALLEY CONFERENCE
Woodstock schools to discuss leaving FVC By JOE STEVENSON and JEFF ARNOLD joestevenson@shawmedia.com jarnold@shawmedia.com Woodstock and Woodstock North may be looking to join another conference for athletics. Under “New Business” on the District 200 school board’s agenda for
Tuesday’s meeting is an item “Fox Valley Conference Discussion.” The item says that there will be discussion “regarding the creation of and participation in a new athletic conference.” Neither athletic director, Glen Wilson of Woodstock nor Nic Kearfott of Woodstock North, returned phone calls on the subject Friday.
Woodstock boys basketball coach Alex Baker said the coaches were instructed to keep any discussion before the meeting “in-house.” Woodstock North opened in the 2009-10 school year, and the enrollment is now almost split between the schools with North at 918 students and Woodstock at 957. Johnsburg (766) is leaving for the Big Northern
Conference after this school year, which will leave Hampshire (1,185) as the next-smallest FVC school besides the Woodstocks. Woodstock and Woodstock North would fit well geographically with the BNC. If they would move that direction, it would bring the BNC membership to 18, divided into two nine-team divisions for most sports.
CLASS 4A HUNTLEY SUPERSECTIONAL PREVIEW
Gators close in on goal
Kyle Grillot – kgrillot@shawmedia.com
Crystal Lake Central senior Ryan Pitner races toward the finish line during the Fox Valley Conference cross country meet last month in Woodstock. Pitner will compete in the state meet Saturday in Peoria.
CROSS COUNTRY STATE MEET PREVIEW
Spotlight intense at state CLC’s Pitner able to lock in on race By JOE STEVENSON joestevenson@shawmedia.com
Kyle Grillot – kgrillot@shawmedia.com
Crystal Lake South players celebrate a point against Gurnee Warren on Thursday during the Class 4A Belvidere North Sectional in Belvidere. South won in two games.
CL South needs 1 more win to reach state semifinals By MAUREEN LYNCH
Supersectional pairing
sportsdesk@nwherald.com.”
Crystal Lake South vs. Lake Zurich, 6:30 p.m. Saturday at Huntley
Winner will play Normal or Benet in the state semifinals at 7:30 p.m. Friday in Normal..
See CL SOUTH, page C3
Kyle Grillot – kgrillot@shawmedia.com
Crystal Lake South’s Katy Hoenle (left) and Gurnee Warren’s Rachel Siegler fight to push the ball toward each other’s side of the court Thursday in Belvidere..”
See CROSS COUNTRY, page C3
CLASS 3A ANTIOCH SUPERSECTIONAL PREVIEW
Familiar foe awaits Marian By MEGHAN MONTEMURRO mmontemurro@shawmedia.com The last time Marian Central met Chicago Payton in a supersectional remains firmly etched in Marian Central coach Laura Watling’s memory. Watling, then an assistant to coach Deb Rakers, witnessed the Hurricanes fall apart in the Class 3A Grayslake Supersectional in 2008 against Payton, blowing a one-game lead with an ugly performance to deny them a state appearance. It’s a loss Watling hasn’t forgotten. Watling and the Hurricanes have a chance to avenge that upset at 1 p.m. Saturday in the Class 3A Antioch Supersection-
Supersectional pairing Marian Central vs. Chicago Payton, 1 p.m. Saturday at Antioch
Winner will play Champaign Centennial or LaSalle-Peru at 4:30 p.m. Friday in the state semifinals in Normal. al. With a win against Payton, Marian would advance to the state finals for the third time in four seasons. In 2010, the Hurricanes beat Payton in the thirdplace game, 2-0. “It’s not hard to believe, but it’s surreal,” senior middle blocker Hannah Davis said of being on the cusp of the state
finals. Marian hasn’t relied on just one unit to carry the team through the postseason. Whether it’s the Hurricanes’ athletic blockers slowing down opponents’ hitters or their offense stepping up as it did in their Burlington Sectional final win on Thursday. Marian’s versatility has created a dangerous team. A confident group heading into Saturday’s supersectional after finding a way to win the sectional title despite not playing their best against Burlington Central, the Hurricanes can’t be overlooked even with a 23-16 record.
See MARIAN, page C3
Sarah Nader – snader@shawmedia.com
Marian Central’s Alex Kaufmann dives for the ball during Thursday’s Class 3A Burlington Central Sectional final against Burlington Central. Marian won in three games.
SPORTS
Page C2 • Saturday, November 9, 2013
Northwest Herald / NWHerald.com
Dolphins mess isn..”
BEARS INSIDER Hub Arkush
ing Dolphins players about why they didn’t intervene or speak up on Martin’s behalf is that Martin made them feel as if he and Incognito were buddies. Martin regularly shared Incognito’s vulgarities with his teammates and laughed the loudest, indicating he understood the culture that allowed them and was proud to be a member. There is never an excuse for bully-
• Hub Arkush covers the Bears for Shaw Media and HubArkush.com. Write to him a harkush@shawmedia.
Johnsburg’s Fiedorowicz tries to help Iowa become bowl-eligible Northwest-
due. He also has a touchdown reception in each game.
NFL: Dallas at New Orleans, 7 p.m. Sunday, NBC
College football: Illinois at Indiana, 2:30 p.m. Saturday, BTN
Paige Elaine of West Dundee is in her first season with the Dallas Cowboys’ cheerleading squad.
MUST-SEE TV NFL: Detroit at Bears, noon Sunday, Fox
qu.
The winner of this tournament gets an automatic bid to the NCAA tournament. Cary-Grove graduate Erin Holland is a freshman midfielder/defender for Mar- Mc-
C.
8SPORTS SHORTS.
Think you’re a football pro? See if you can outpick our experts!
NOTE: VIP records reflect their actual picks. Record equals picks plus any extra points the website may award. VIP final picks may vary from what is published in this advertisement.
Hub Arkush
Dan Hampton
Football Analyst HubArkush.com
Ed Graafsma
Jeremy Brock
Rhett Wilborn
Alexander Lumber
Cardinal Wines & Liquors
Innovative Home Concepts, Inc.
Last Week’s Record 7-6 Overall Record 86-47
Last Week’s Record 9-4 Overall Record 89-44
Last Week’s Record 7-6 Overall Record 84-49
Last Week’s Record 9-4 Overall Record 87-46
Last Week’s Record 7-6 Overall Record 77-56*
Washington
Minnesota
Washington
Minnesota
Washington
Broncos coach Fox out of hospital after surgery
WEEK #10
ENGLEWOOD, Colo. –.
Seattle@Atlanta
Seattle
Seattle
Seattle
Seattle
Seattle
Detroit@Chicago
Detroit
Detroit
Chicago
Chicago
Chicago
Washington@Minnesota
Philadelphia@Green Bay
Green Bay
Philadelphia
Philadelphia
Philadelphia
Philadelphia
Jacksonville@Tennessee
Tennessee
Tennessee
Tennessee
Tennessee
Tennessee
St. Louis@Indianapolis
Indianapolis
Indianapolis
Indianapolis
Indianapolis
Indianapolis
Oakland@NY Giants
NY Giants
NY Giants
NY Giants
NY Giants
NY Giants
Buffalo@Pittsburgh
Buffalo
Pittsburgh
Pittsburgh
Pittsburgh
Pittsburgh
Baltimore
Cincinnati
Cincinnati
Cincinnati
Cincinnati
San Francisco
San Francisco
San Francisco
San Francisco
San Francisco
Cincinnati@Baltimore Carolina@San Francisco Denver@San Diego
San Diego
Denver
Denver
Denver
Denver
Houston@Arizona
Arizona
Arizona
Arizona
Arizona
Arizona
Dallas@New Orleans
New Orleans
New Orleans
New Orleans
New Orleans
New Orleans
Miami@Tampa Bay
Miami
Miami
Miami
Miami
Miami
Johnson wins Phoenix pole AVONDALE, Ariz. – Jimmie Johnson, his eyes squarely on a sixth NASCAR championship, set the tone for what could be yet another dominating weekend in the desert by winning the pole at Phoenix International Raceway. The five-time NASCAR champion turned a lap of 139.222 mph in his Hendrick Motorsports Chevrolet on Friday to break the track record of 138.766 set by Kyle Busch in November 2012. Matt Kenseth, who trails Johnson by seven points in the standings, will start 14th Sunday in his Joe Gibbs Racing Toyota. – Wire reports
*Rhett Wilborn missed the first week of the contest.
TEAMS ON BYE WEEK: Cleveland, Kansas City, New England, NY Jets
WIN GREAT PRIZES!!
WEEK #9 RESULTS OVERALL LEADERS headfirst, jasonyates, KristinM, webgoers, seanpatf
WEEK #9 WINNER James Luetke, DeKalb, IL To play, go to shawurl.com/upickem
COLLEGE & PREPS
Northwest Herald / NWHerald.com
8INSIDE CROSS COUNTRY Athlete of the week Boys RYAN PITNER Crystal Lake Central, sr. Pitner won the IHSA Class 2A Belvidere Sectional Meet last Saturday in 15:09.09 to help the Tigers to third place as a team. Pitner ran right behind Dixon’s Simon Thorpe for most of the race, then made his move in the final 800 meters and won by 12 seconds. It was his first sectional title. Central will be running in the state meet Saturday at Detweiller Park. It’s the Tigers’ fourth consecutive trip to the state meet. Girls MAURA BEATTIE Woodstock, sr. Beattie won the Class 2A Belvidere Sectional last Saturday in 17:43.98, beating DeKalb’s Kelsey Schrader by 3.5 seconds. It was Beattie’s first sectional title and she led the entire race. Beattie will finish her career in the IHSA Cross Country State Meet this Saturday at Peoria’s Detweiller Park. Beattie has lost only one race this season and likely will be one of the top finishers in Class 2A.
Noteworthy Fast rookie: Prairie Ridge freshman Filip Pajak has turned in an impressive season for his first at the high school level and will run in the Class 2A boys race at Saturday’s state meet in Peoria. Pajak finished 11th to lead the Wolves, who will be competing as a team. “That was my goal to make it to state,” Pajak said. “I wasn’t expecting too much out of it. I kept that goal in mind every time I ran.” Wolves coach Judd Shutt knew Pajak was fast, but marvels still at his progress. “He could do the training with all the top runners, but usually that doesn’t translate to running ability because you have a young body who doesn’t put the speed in in the last 800 meters of the race,” Shutt said. “So he’s really surprised me. He makes up for it by mental toughness. He’s really proved that he does belong. He should have his eyes up there, this is a tough sectional. There’s no reason he can’t be setting a pretty high goal for what he can place at state.” Next generation: Marian Central freshman Abby Jones will run in the Class 1A girls race at the state meet Saturday. Jones is the daughter of former Hurricanes distance star Laura Witek Jones. Witek was a Class A All-State runner in 1990, 1991 and 1992, as well as a distance standout in track and field.
Big day for Beattie sisters, LZ boasts 35-4 record Wildcats in cross country • CL SOUTH Continued from page C1
ON CAMPUS Barry Bottino When Kayla Beattie stepped to the start line at the Pac-12 Championships cross country meet in Colorado last week, she had a confident thought. “I knew it was going to be a good day for the Wildcats,” said Beattie, a Woodstock graduate. Beattie, a sophomore for the University of Arizona’s Wildcats, already knew that her sister Elise’s team, the University of New Hampshire Wildcats, had won the America East Conference title earlier in the day. Kayla Beattie followed through by finishing fifth in the 6-kilometer race in 21:20 to lead Arizona – ranked No. 1 in the nation – to its first conference title in school history. “It was definitely an exciting weekend for us,” Kayla Beattie said. At the America East race at Binghamton (N.Y.) University, Elise Beattie, a senior who also graduated from Woodstock, placed 11th in 18:09.65 for UNH, which won the 5K conference title race after finishing second for the past three years. “We knew we had a decent chance of winning, but all the pieces had to go together,” Elise Beattie said. UNH had its top five runners finish between sixth and 12th place. “I was glad to be able to push my teammates and have my teammates push me,” Elise Beattie said. In her first season at Arizona after transferring from Iowa, Kayla Beattie finished in the top seven in every meet and won two individual titles this fall. “I’m happy,” said Beattie, who battled illness during her three semesters at Iowa. “When you’re happy, you perform your best. I feel really good, for the first time in two years.” Kayla Beattie said she has been diagnosed with “a couple of [gastrointestinal] conditions,” including Celiac disease, an immune reaction to eating gluten. “It’s a disease, but it can be fixed,” she said. “I eat a lot of natural, organic foods. I pack a lot of my own snacks and we call ahead to restaurants (on the road). The coaches
Class 1A Girls, 9 a.m. Local qualifiers Team Harvard: Jazmin Anaya, Daphne Austin, Taylor Binz, Javauneeka Jacobs, Morgan Logan, Jordan Peterson, Katie Wright. Individuals Abby Jones (Marian Central). Class 1A Boys, 10 a.m. Local qualifiers Individuals Jorge Pichardo (Harvard). Class 2A Girls, 11 a.m. Local qualifiers Teams Crystal Lake Central: Maddie Dagley, Mary Fleming, Kelly Doerr, Janine Orvis, Brooke Larsen, Avery Robertson, Rachel Kautz. Marengo: Kitty Allen, Allie Sprague, Ashlynd Broling, Katie St. Clair, Kaylin Punotai, Sarah Shefcik. Individuals Maura Beattie (Woodstock), Kate Jacobs (Woodstock), Erin Wagner (Prairie Ridge). Class 2A Boys, noon Local qualifiers Teams Crystal Lake Central: Ryan Pitner, Nick Amato, Zach Gemmel, P.J. McKay, Michael Penza, Cole Barkocy, Jake Cannizzo. Prairie Ridge: Filip Pajak, Mitch Kazin, Scott Hearne, Jude Mariutto, Tyler Figgins, Chris Berg, David Tulke. Individuals Luke Beattie (Woodstock). Class 3A Girls, 1 p.m. Local qualifiers Individuals Talia Duzey (Cary-Grove), Morgan Schulz (Cary-Grove), Lauren Van Vlierbergen (Jacobs), Lauren Opatrny (McHenry), Katie Purich (McHenry). Class 3A Boys, 2 p.m. Local qualifiers Individuals Jesse Reiser (McHenry), Matt Johnson (Jacobs), Keagan Smith (Huntley).
– Joe Stevenson joestevenson@shawmedia.com
Photo courtesy of Pac-12 Conference
Woodstock graduate Kayla Beattie competes with Arizona’s cross country team this season. Arizona won the Pac-12 championship. have been great about it.” Elise Beattie has dealt with her own challenge the past two semesters. As a nursing major, she has had clinical rotations at a hospital off campus as part of her coursework since last winter. “You’re off campus and you’re on your feet a lot,” she said. “But this semester hasn’t been too bad for me.” The sisters have at least one more race remaining. Arizona will compete in the NCAA West Regional Nov. 15 in Sacramento, Calif., and New Hampshire races the same day at the Northeast Regional in New York City.
D-III website honors PR grad: Dubuque University senior quarterback Bryan Bradshaw was named to D3Football. com’s Team of the Week on Tuesday after passing for a school- and Iowa Intercollegiate Athletic Conference-record 500 yards and four touchdowns in a 50-46 loss Nov. 2 to Simpson. Bradshaw, a Prairie Ridge grad, was 27 for 39 passing and finished with 513 yards of total offense. He threw TDs of 3, 13, 13 and 31 yards with no interceptions for the Spartans (4-4). For the season, Bradshaw leads the conference in passing yards a game (301.2) and passing TDs (24). Horizon hotshot: Wisconsin-Milwaukee freshman women’s soccer goalkeeper Paige Lincicum (Cary-Grove) was named Monday as the Horizon League’s Defensive Player of the Week. Lincicum made five saves Nov. 1 in a 1-0 victory against Oakland that clinched the regular-season conference title for the Panthers (8-8-1), who have won 14 league titles in a row. The victory against Oakland was Lincicum’s third shutout of the season.
Iowa soccer standout: CaryGrove grad Tommy Breen, a sophomore goalkeeper at Luther College, was named Monday as the Iowa Conference men’s soccer Defensive Player of the Week while helping the team to a share of the league title. In 1-0 victories last week against Wartburg and Central, Breen made a combined 10 saves. Against Central, he stopped two penalty shots. He has compiled five shutouts this season for the Norse (14-6) and a 0.81 goals-against average. Top Colonel: Marian Central grad Dena Ott, a junior libero for D-I Eastern Kentucky’s volleyball team, won the Ohio Valley Conference Defensive Player of the Week award on Monday. Ott had 50 combined digs in wins last week against Jacksonville State and Tennessee Tech. Ott led all players with 26 digs against JSU and 24 against TTU. Ott ranks third in the OVC this season with 4.77 digs per set for EKU (15-13). Petty paces Stars: Kelly Petty, a senior forward for D-III Dominican University’s women’s soccer team, was chosen for the All-Northern Athletics Collegiate Conference second team this month. A Marian Central grad, Petty led the Stars (3-12-1) with 11 goals, four assists and 26 points this season. Her 38 career goals is the third-highest total in school history.
The winner will face the winner of the Normal Supersectional between Normal and Benetu-
• CROSS COUNTRY Continued from page C1 “The second the gun goes off, I don’t think about the nerves any more, it’s all putting the energy in running the race I can.” The better a runner can focus and block things out, the better he or she
I. A public hearing to approve a proposed property tax levy increase for Cary Community Consolidated School District No. 26, McHenry and Lake Counties, Illinois for 2013 will be held on Monday, November 18, 2013 at 7:00 p.m. at Cary Junior High School, 2109 Crystal Lake Road, Cary, Illinois 60013. Any person desiring to appear at the public hearing and present testimony to the School District may contact Jeffrey Schubert, Director of Finance and Operations for Cary Community Consolidated School District No. 26, 2115 Crystal Lake Road, Cary, Illinois 60013, 847-639-7788. II. The corporate and special purpose property taxes extended or abated for 2012 were $19,871,013.58. The proposed corporate and special purpose property taxes to be levied for 2013 are $20,854,707. This represents a 4.95% increase over the previous year. III. The property taxes extended for debt service and public building commission leases for 2012 were $3,708,595.14. The estimated property taxes to be levied for debt service and public building commission leases for 2013 are $4,600,474.25. This represents a 24.05% increase over the previous year. IV. The total property taxes extended or abated for 2012 were $23,579,608.72. The estimated total property taxes to be levied for 2013 are $25,455,181.25. This represents a 7.95% increase over the previous..”
Marian’s record misleading • MARIAN Continued from page C1 “I feel like we’re in one of the hardest conferences in the state, so a lot of times our record is deceiving,” Davis said. “The combination of that and playing [strong teams], it really hurts our record. So during postseason we’re like, surprise!” Senior outside hitter Frankie Taylor credits the Hurricanes coming together as a team over the course of the season as the biggest reason for their success. The players regularly send daily text messages to each other, offering words of encouragement without prompting from their coaches. “I’ve never been so close with a team,” Taylor said. “You can ask anybody on the team out of the 15 girls we have, it’s about working as a team. We all do it and it’s not an individual sport at all. Everyone has to be on and has to push. It’s not
a roller coaster anymore; it’s straight to the top.” Payton (26-11) last appeared in the state finals in 2010, finishing fourth in Class 3A. The Grizzlies, however, have won a sectional title in four of the past six seasons. Olivia Rozmus is one of Payton’s go-to hitters. She led the team with 13 kills in the sectional final win Thursday against Chicago Latin. A common opponent this season between the two teams is St. Ignatius. The Grizzlies lost to St. Ignatius, 2-0, while Marian won, 2-1. Asked if she thought at the beginning of the season Marian would reach this point of the playoffs, Watling said, “not at all.” “I knew we had talent, but because we are so young, I didn’t know if we would have the mental attitude and the confidence to put it all together by the time we got here,” Watling said. “They’ve been working hard and it’s been fantastic to see.”
rich.”
NOTICE OF PROPOSED PROPERTY TAX INCREASE FOR CARY COMMUNITY CONSOLIDATED SCHOOL DISTRICT NO. 26, MCHENRY AND LAKE COUNTY, ILLINOIS
McHenry’s Reiser 7th at state in 2012
IHSA State Meet At Peoria’s Detweiller Park
Saturday, November 9, 2013 • Page C3
TRAIN HARD. PLAY BETTER. 1269 Cobblestone Way, Woodstock Easy access from Hwy 47 or Hwy 14 Located behind Woodstock Sears Outlet
815-334-1900
|
Chicago Bandits Girls Softball Catchers Clinic Learn from the Pro’s at SportsCity Academy. Sunday Nov 24th. Join Bandit players Jenna Grimm & Brittany Cervantes. Sign up online or call to reserve your spot. Ages 9-18. Space is Limited.
SPORTS
Page C4 • Saturday, November 9, 2013
Northwest Herald / NWHerald.com
ILLINOIS AT INDIANA, 2:30 P.M., BTN, BTN2
Fighting Illini face potent Hoosiers’ offense By STEVE GREENBERG Chicago Sun-Times Five things I don’t want to know yet about Illinois’ game at Indiana on Saturday but am afraid I already do: 1. To paint a picture of how explosive Indiana’s offense is, consider that the 2012 Hoosiers – who ranked second in the Big Ten in total offense – had 17 touchdown drives that took five or fewer plays to execute. This year’s offense has 27 such drives already. If
MEN’S COLLEGE BASKETBALL ROUNDUP
Michigan State rolls in opener No. 2 Michigan State 98, McNeese State 56: At East Lansing, Mich., Gary Harris flourished, as expected, scoring 15 of his 20 points in the first half and finishing with a career-high 10 rebounds to help No. 2 Michigan State beat McNeese State on Friday night in a tuneup for its next game against top-ranked Kentucky.
Indiana 100, Chicago State 72: At Bloomington, Ind., Jeremy Hollowell scored a career-high 16 points and had four blocks, and Noah Vonleh added 11 points, 14 rebounds and three blocks in his college debut, leading Indiana past outmanned Chicago State.
Purdue 77, Northern Kentucky 76: At West Lafayette, Ind., Ronnie Johnson had 18 points and five assists to lead Purdue to a victory over Northern Kentucky. Jay Simpson had 14 points and six rebounds and Errick Peck had 11 points and nine rebounds for the Boilermakers (1-0), who never found a way to pull away.
Michigan 69, UMass-Lowell 42: At Ann Arbor, Mich., the Wolverines raised their Final Four banner from last season to the rafters Friday night, then dispatched Division I newcomer UMass-Lowell behind 15 points from Glenn Robinson III. Minnesota 81, Lehigh 62: At Minneapolis, Minn., Richard Pitino earned his first victory as Minnesota’s coach Friday night, a win over Lehigh behind 20 points from newcomer Joey King. Andre Hollins added 18 for the Gophers.
No. 20 Wisconsin 86, St. John’s 75: At Sioux Falls, S.D., despite relying on some new faces and playing in a strange location, No. 20 Wisconsin continued its mastery in season openers, beating St. John’s.
No. 14 VCU 96, Illinois State 58: At Richmond, Va., transfer Terrance Shannon and Treveon Graham led VCU with 14 points each, Juvonte Reddic had 13 and eight rebounds and the Rams used a 33-7 first-half run to take command in the season opener for both teams.
Arkansas 99, Southern Illinois-Edwardsville 65: At Fayetteville, Ark., Anthlon Bell had 18 points and Michael Qualls added 16 as five players finished in double figures in a season-opening win for Arkansas over Southern Illinois-Edwardsville.
Nebraska Omaha 68, Northern Illinois 66: At DeKalb, Ill., CJ Carter scored on a 3-point play Friday night to help Omaha take the lead in the final seconds and hold on to a narrow victory over Northern Illinois.
Nebraska 79, Florida Gulf Coast 55: At Lincoln, Neb., Shavon Shields scored 28 points, Terran Petteway added 17 and Nebraska celebrated the opening of the new Pinnacle Bank Arena with a victory over Florida Gulf Coast on Friday night.
Iowa 82, UNC-Wilmington 39: At Iowa City, Iowa, Sophomore Jarrod Uthoff had 14 points and four blocks in his Iowa debut and the Hawkeyes rolled past UNC-Wilmington Friday in its season opener.
the Hoosiers get that number to 30 against Illinois, they’ll have their second Big Ten victory. 2. Quarterback Nathan Scheelhaase must average 357 total yards over the final four games to break Juice Williams’ Illinois career record of 10,594. Care to guess how many times the senior has gone for at least 357 this season? Try just once, in the opener against Southern Illinois. (He had 356 total yards last
weekend at Penn State.) Indiana, though, is an opportunity for Scheelhaase to throw – and run – for a ton of yards. We’ll throw caution to the wind and say he amasses close to 400 against the Hoosiers. 3. Somehow, Indiana has an even worse rushing defense than Illinois, ranking 114th nationally in that category (allowing 224.1 yards per game) to the Illini’s 113th (223.1). And yet watch as the Hoo-
siers work much harder than the Illini to establish their run game. IU’s Tevin Coleman and Stephen Houston are weapons, but this is more about Illini offensive coordinator Bill Cubit’s refusal to believe in his own ground attack. Cubit should look to get Josh Ferguson and even Donovonn Young going early, especially given Indiana’s quick-strike offense, but will he? Don’t bet on it. 4. Illinois’ play in the secondary last week really
wasn’t bad at all – and that’s saying something for a unit that had done almost nothing all season to help the cause. Now comes a massive test in the form of three Hoosiers wideouts – Shane Wynn, Cody Latimer and Kofi Hughes – who are legitimate home run hitters. Beckman believes his group of young cornerbacks is beginning to come around, but this matchup will set them back a ways. 5. In four games this sea-
son, Indiana has kept its quarterbacks clean, not allowing a single sack. The Hoosiers are allowing one sack per 29 pass attempts, a very respectable number. Given the Illini’s blatant inability to rush the passer, this swings all the analysis in favor of the home team. Another long afternoon for Tim Banks’ defense.
• Steve Greenberg is a Chicago Sun-Times sports reporter who can be reached at sgreenberg@suntimes.com.
NO. 24 NOTRE DAME AT PITTSBURGH, 7 P.M., ABC
Irish will try to find a way again versus Pitt By WILL GRAVES
ROLLING REES
The Associated Press
AP file photo
Notre Dame tight end Troy Niklas crosses the goal line for a touchdown Aug. 31 against Temple in South Bend, Ind.
“Personally I don’t like Notre Dame at all. It’s going to make me play harder ... I just think they’re really cocky and their coaches are really cocky so I just don’t like that.” J.P. Holtz, Pitt sophomore tight end10 loss to Georgia Tech last week. The senior recorded 11 tackles, six tackles for loss, two forced fumbles and a sack. He is the heart of a de-
fense.
ILLINOIS 80, ALABAMA STATE 63
Illinois opens season with win over Alabama State Champaign native Rayvonte Rice has 22 points, nine rebounds in debut for Illini By DAVID MERCER The Associated Press CHAMPAIGN, Ill. – Ray and had eight boards. Jamel Waters led Alabama State (0-1) with 27 points. He was 5-of-6 from 3-point range. Rice was never seriously recruited by Illinois. So he went to Drake before head coach John Groce, in his first season, lured him back. Rice had to sit out a season under NCAA transfer rules, a
year Groce has said the stocky guard put to good use, taking off fat and adding muscle.. Rice was 9-for-10 from the free-throw line, and Illinois as a team went 22-for-30, 73.3 percent. Illini host Jacksonville State on Sunday. The Hornets will travel across Illinois to face Bradley.
AP photo
Illinois guard Joseph Bertrand (center) collides with Alabama State forward Maurice Strong (left) during the first half Friday in Champaign.
FINE PRINT
Northwest Herald / NWHerald.com
Saturday, November 9, 2013 • Page C5
BULLS 97, JAZZ 73
FIVE-DAY PLANNER
Jazz just what Bulls needed By JOE COWLEY Chicago Sun-Times CHICAGO – Joakim Noah was smirking before the question posed to him was even finished. Of course the center had heard the comments from Pacers forward Paul George. The entire Bulls locker room had. “We want to step away from that shadow as the ‘little brothers’ of this division,” George told NBA. com after the 97-80 Indiana win Wednesday night. “[The Bulls’] success is the Michael Jordan era. This is a new age, this is a new team. It’s ours till they take it.” Hard to argue considering Indiana is now 6-0. But getting Utah on Friday night was at least a good place for the Bulls to start. Thanks to Luol Deng falling just an assist short of a triple-double, the Bulls improved to 2-3 with the 97-73 win over the winless Jazz (06). “It’s all good,” Noah said of George’s comment. “It’s Game 5 of the season, man. It’s a long journey. We’ll see those guys again.” Next week, as a matter of fact. But looking ahead is the last thing this Bulls team can do. Sure it was only Utah, but it was the first complete game the starters have really had this season, as Derrick Rose, Noah, Deng and Carlos Boozer each scored in double-digits, led by Deng’s 19 points, 11 rebounds and nine assists, as well as five steals. Deng had a chance to record
AP photo
Bulls forward Carlos Boozer (right) goes to the basket against Utah Jazz forward Derrick Favors during the first quarter Friday at the United Center. the first triple-double of his career in the fourth, but Nazr Mohammed had two consecutive misses off Deng passes, before coach Tom Thibodeau pulled his small forward. “Close to the triple-double, it didn’t happen, move on to the next one,” Deng said. “It would have been cool, but there’s two sides to it. On one side there’s, ‘It took him 10 years to get it.’ The other side is, man I’ve been close many times, so that’s the other side. But I’m really not worried about it at all.’’ He shouldn’t be. There’s been enough for this team to be con-
cerned about through the first two weeks of the regular season. The energy on defense had been low, the turnovers high, and the play of Rose erratic. Nothing a game against Utah couldn’t cure, especially in an opening quarter in which the Bulls came out and jumped up 30-18 after the first 12 minutes. “I thought the first quarter was terrific,” Thibodeau said. “I thought that set the tone for the game. Our starters made sure that the group functioned well together, and that was a big plus for us.” Deng was a big reason, as he came out and scored seven points with five assists in that first quarter. “He was terrific,” Thibodeau said. “I thought there was a lot of unselfish play, guys making the extra pass. I thought the screening was a lot better, hitting the open man, running the floor, great effort defensively, and that’s what it’s going to take.” As for Rose, while he only had 12 points, he did go 5 for 5 from the free throw line, as well as hand out five assists. “We’ll take any win,’’ Rose said. “It feels good that we were just executing our offense and getting in a groove. We haven’t had a groove in any of our games that we played in before [Friday], but we can’t get hyped because we won just one game.’’ • Joe Cowley is a Chicago Sun-
Times sports reporter who can be reached at jcowley@suntimes.com.
HARVARD 56, CHICAGO KING 16 King Harvard
0 0 8 8 35 21 0 0
– 16 – 56
First quarter H– Kramer 58 run (Schneider kick), 11:44. H– Kramer 19 run (Schneider kick), 10:59. H– Nolen 30 pass from Schneider (Schneider kick), 9:43. H– Mejia 2 run (Schneider kick), 7:48. H– Nolen 42 pass from Schneider (Schneider kick), 5:30. Second quarter H– Wheeler 1 run (Platt kick), 9:12. H– Nolen 48 interception return (Platt kick), 8:52. H– Rudd 1 run (Platt kick), 0:18. Third quarter K– P. Powell 35 pass from N. Powell (P. Powell pass from N. Powell), 0:08. Fourth quarter K– Tucker 15 pass from N. Powell (N. Powell run), 6:57. INDIVIDUAL STATISTICS RUSHING– King: N. Powell 11-55, Harris 3-12, Robinson 7-3. Totals: 25-70. Harvard: Kramer 7-136, Platt 6-61, Mejia 8-40, Rudd 6-23, Clark 5-12, Quinn 4-6, Wheeler 1-1, Reilly 1-0, Overles 1-0. Totals: 40-282. PASSING– King: N. Powell 10-24-1161. Harvard: Schneider 6-8-0-93. RECEIVING– King: P. Powell 4-66, McHone 3-70, Harris 1-17, Tucker 1-15, Kennedy 1-3. Harvard: Nolen 4-87, Reilly 1-4, Miller 1-2. TOTAL TEAM YARDS: King 153, Harvard 375.
PLAYOFF PAIRINGS Class 1A Second Round No. 1 Stockton (10-0) at No. 5 Galena (8-2), Saturday, 1 p.m. No. 7 Freeport Aquin (7-3) at No. 6 Lena-Winslow (7-3), Saturday, 1 p.m. No. 4 Abingdon-Avon (8-2) at No. 1 Ottawa Marquette (10-0), Saturday, 3 p.m. No. 2 Toulon Stark County (9-1) vs. No. 6 Chicago Leo (8-2) at Chicago St. Rita, Saturday, 2 p.m. No. 1 Downs Tri-Valley (10-0) at No. 9 Argenta-Oreana (8-2), Saturday, 4 p.m. No. 5 Carrollton (9-1) at No. 4 CaseyWestfield (10-0), Saturday, 2 p.m. No. 2 Maroa-Forsyth (10-0) vs. No. 10 Arthur-Lovington [Coop] (8-2) at ArthurLovington, Saturday, 1:30 p.m. No. 6 Mt. Sterling (Brown County) (9-1) at No. 3 Camp Point Central (10-0), Saturday, 1 p.m. Class 2A Second Round No. 1 Pearl City [Eastland-P.C. Coop] (10-0) at No. 5 Sterling Newman Central Catholic (9-1), Saturday, 2 p.m. No. 7 Momence (7-3) at No. 6 Spring Valley Hall (7-3), Saturday, 2 p.m. No. 1 Taylor Ridge Rockridge (10-0) at No. 5 Aledo (Mercer County) (9-1), Saturday, 1 p.m. No. 3 Elmwood [E.-Brimfield Coop] (9-1) at No. 2 Farmington (9-1), Saturday, 1 p.m. No. 1 Cerro Gordo [C.G.-Bement Coop] (10-0) at No. 5 Athens [Coop] (7-3), Saturday, 1 p.m. No. 3 Carlinville (8-2) at No. 2 Auburn (8-2), Saturday, 1:30 p.m. No. 4 Carlyle (9-1) at No. 8 Staunton (6-4), Saturday, 1 p.m. No. 3 Gillespie (9-1) at No. 7 CarmiWhite County (7-3), Saturday, 2 p.m. Class 3A Second Round No. 8 Kankakee (McNamara) (7-3) at No. 1 Winnebago (10-0), Saturday, 1:30 p.m. No. 4 Erie-Prophetstown [Coop] (8-2) vs. No. 5 Stillman Valley (8-2) at Erie, Saturday, 1:30 p.m. No. 15 Oregon (6-4) at No. 10 Aurora Christian (7-3), Saturday, 6 p.m.
No. 14 Chicago Robeson (7-3) vs. No. 6 Seneca (8-2) at Chicago Gately Stadium, Saturday, 1 p.m. No. 4 Tolono Unity (8-2) at No. 1 Williamsville (10-0), Saturday, 5 p.m. No. 3 St. Joseph-Ogden (8-2) at No. 2 Monticello (9-1), Saturday, 2 p.m. No. 4 Robinson (8-2) at No. 1 Greenville (10-0), Saturday, 1 p.m. No. 3 Mt. Carmel (9-1) at No. 2 Carterville (10-0), Saturday, 1 p.m. Class 4A Second Round No. 1 Evergreen Park (10-0) vs. No. 9 Chicago Phillips (7-3) at Chicago Gately Stadium, Saturday, 5 p.m. No. 5 Plano (9-1) at No. 4 Geneseo (9-1), Saturday, 1 p.m. No. 2 Harvard 56, No. 7 Chicago King 16 No. 6 Rockford Lutheran (9-1) at No. 14 Rochelle (6-4), Saturday, 1 p.m. No. 4 Herrin (8-2) at No. 8 Belleville Althoff Catholic (6-4), Saturday, 1 p.m. No. 2 Rochester (9-1) at No. 6 Breese Mater Dei (7-3), Saturday, 1:30 p.m. No. 4 Peotone (8-2) at No. 1 Quincy Notre Dame (9-1), Saturday, 3 p.m. No. 3 Rock Island Alleman (8-2) at No. 2 Mahomet-Seymour (9-1), Saturday, 1 p.m. Class 5A Second Round No. 1 Lombard Montini (10-0) at No. 9 Marian Central (8-2), Saturday, 6 p.m. No. 5 Maple Park Kaneland (9-1) at No. 4 Joliet Catholic Academy (9-1), Saturday, 7 p.m. No. 2 Sycamore (10-0) at No. 10 LaGrange Park Nazareth Academy (8-2), Saturday, 1 p.m. No. 6 Lincoln-Way West (9-1) at No. 3 Glenbard South (10-0), Saturday, 1 p.m. No. 1 Springfield Sacred Heart-Griffin (10-0) at No. 9 Chatham Glenwood (8-2), Saturday, 1 p.m. No. 5 Bartonville Limestone (9-1) at No. 4 Highland (10-0), Saturday, 2 p.m. No. 2 Washington (10-0) at No. 10 Mt. Vernon (H.S.) (7-3), Saturday, 1:30 p.m. No. 3 Normal (University) (10-0) at No. 11 Jacksonville (H.S.) (7-3), Saturday, 1 p.m. Class 6A Second Round No. 1 Rockford Boylan Catholic (10-0) at No. 9 Cary-Grove (7-3), Saturday, 1 p.m. No. 5 Aurora Marmion Academy (8-2) at No. 13 Prairie Ridge (6-4), Saturday, 1 p.m. No. 2 Batavia (9-1) at No. 10 Rolling Meadows (7-3), Saturday, 6 p.m. No. 6 Lake Forest 27, No. 14 Chicago De La Salle 7 No. 4 Summit Argo (8-2) at No. 1 Oak Lawn Richards (9-1), Saturday, 6 p.m. No. 2 Lincoln-Way North 38, No. 3 Olympia Fields Rich Central 6 No. 8 New Lenox Providence Catholic (6-4) at No. 5 Quincy (8-2), Saturday, 3 p.m. No. 2 Normal Community (9-1) at No. 6 East St. Louis (7-3), Saturday, 1 p.m. Class 7A Second Round No. 8 Rockton Hononegah (8-2) at No. 1 Lake Zurich (9-1), Saturday, 1 p.m. No. 5 Wheaton North (8-2) at No. 4 Oak Park Fenwick (9-1), Saturday, 7 p.m. No. 2 Schaumburg (9-1) vs. No. 10 Chicago St. Patrick (7-3) at Chicago Hanson Stadium, Saturday, 1 p.m. No. 3 Glenbard West (9-1) at No. 11 Hoffman Estates Conant (7-3), Saturday, 1 p.m. No. 8 Downers Grove North 10, No. 5 Wheaton Warrenville South 7 No. 2 Chicago Mt. Carmel 20, No. 3 Chicago St. Rita 15 No. 1 Edwardsville (10-0) at No. 5 Bradley-Bourbonnais (7-3), Saturday, 3 p.m. No. 3 Lincoln-Way East (8-2) at No. 7 Oswego East (7-3), Saturday, 1 p.m. Class 8A Second Round No. 1 Wilmette Loyola Academy (9-1) at No. 9 Niles Notre Dame (7-3), Saturday, 6 p.m.
No. 5 Park Ridge Maine South (8-2) at No. 4 Oak Park-River Forest (9-1), Saturday, 1:30 p.m. No. 2 Barrington (9-1) vs. No. 10 Gurnee Warren (7-3) at Gurnee Warren (Oplaine Campus), Saturday, 6 p.m. No. 6 Lincolnshire Stevenson (8-2) at No. 3 Glenbard North (9-1), Saturday, 1 p.m. No. 8 Chicago Marist 21, No. 1 Bolingbrook 7 No. 5 Aurora Waubonsie Valley (8-2) at No. 4 Oswego (8-2), Saturday, 6:30 p.m. No. 7 Naperville Central 24, No. 2 Homewood-Flossmoor 21 No. 6 Chicago Simeon (7-3) at No. 3 Naperville Neuqua Valley (9-1), Saturday, 6 p.m.
GIRLS VOLLEYBALL PLAYOFF PAIRINGS Class 3A Burlington Central Sectional Tuesday Match 1: Marian Central 2, Regina Dominican 0 Match 2: Burlington Central 2, Lakes 0 Thursday Match 3: Marian Central 2, Burlington Central 1 Antioch Supersectional Saturday Match 1: Marian Central vs. Chicago Payton, 1 p.m. Class 4A Belvidere North Sectional Tuesday Match 1: Warren 2, Huntley 0 Match 2: CL South 2, Rockford Boylan 0 Thursday Match 3: CL South 2, Warren 0 Huntley Supersectional Saturday Match 1: CL South vs. Lake Zurich, 6:30 p.m.
BOYS SOCCER ALL-FVC TEAMS Fox Division Crystal Lake Central: Allen Chen, Sr., M; Jacob Sigmund, Jr., D; Michael Chen, So., F; Jordan Fisher, So., D. Grayslake Central: Issac Longenecker, Jr., M; Jonny Madrid, Jr., F; Joey Mudd, Jr., F; Connor Gosell, So., G; Nate Cerquone, Sr., D; Alex Stickler, Sr., M. Grayslake North: Gavin Amburn, Jr., F; Andreas Thedorf, Sr., D; Lucas Buckels, Jr., M; Jake Hensley, Sr., D. Hampshire: Paul Novacovici, Sr., M. Johnsburg: Joe Chamberlain, Sr., D-M; Joe Nikolai, Sr., M; Brad Winter, Sr., D. Woodstock: Julis Arias, So, M-F; James Sullivan, Sr., D; Caleb Schroeder, Jr., F. Woodstock North: Alejandro Mirande, Jr., M; Cody Kupsik, Sr., D; Aaron Jones, Sr., M; Victor Ortiz, Sr., F. Valley Division Cary-Grove: Kevin Wilde, Sr., M-F; Tyler Szydlo, Sr., D. Crystal Lake South: Orlando Tapia, Jr., M; David Tagatz, Sr., D; Matt Tobolt, Sr., M-F; Charlie Ruff, Jr., M. Dundee-Crown: Ben Stone, Sr., M; Carlos Ramos, Sr., D; Francisco Nava, Sr., D; Jose Gonzalez, Jr., G; William Campos, Jr., M. Huntley: Niko Mihalopolous, Sr., F; Jakub Rys, Sr., D; Eduardo Gonzalez, Sr., M; Austen Emery, Sr., G; Jack Bessey, Fr., M; Angel Sanchez, Jr., D. Jacobs: Tim Hubner, Sr., F; Ean Wilson, So., F. McHenry: Evan Hying, Sr., D; Mike Lawrence, Sr., D; Frankie Valle, Sr., G; Luis Beltram, So., F. Prairie Ridge: Nick McCann, Sr., M; Mike Perhats, Sr., M.
GOLF EUROPEAN TOUR
PGA
TURKISH AIRLINES OPEN
THE MCGLADREY CLASSIC
At Montgomerie Maxx Royal Belek, Turkey Purse: $7 million Yardage: 7,100; Par: 72 (35-37) Second Round Leaders Also Francesco Molinari 69-68—137 -7 Martin Kaymer 69-68—137 -7 Padraig Harrington 68-70—138 -6 Charl Schwartzel 68-70—138 -6 Peter Uihlein 67-72—139 -5 Matteo Manassero 70-70—140 -4 Paul Lawrie 74-70—144 E Colin Montgomerie 72-72—144 E Miguel Angel Jimenez 73-71—144 E Louis Oosthuizen 72-74—146 +2
At Sea Island Resort (Seaside Course) St. Simons Island, Ga. Purse: $5.5 million Yardage: 7,005; Par: 70 (35-35) Partial Second Round Leaders Matt Kuchar 68-68—136 -4 Will Claxton 65-71—136 -4 Kevin Stadler 68-68—136 -4 Boo Weekley 67-69—136 -4 D.H. Lee 67-70—137 -3 Scott Langley 66-71—137 -3 Ben Curtis 68-69—137 -3 Martin Flores 70-68—138 -2 George McNeill 62-76—138 -2 Harris English 68-70—138 -2 Heath Slocum 67-71—138 -2 Zach Johnson 70-68—138 -2
SATURDAY
Stuart Appleby Trevor Immelman Aaron Baddeley Andres Romero Pat Perez Paul Goydos Cameron Tringale Kyle Stanley Rory Sabbatini Charley Hoffman Robert Garrigus Spencer Levin Darren Clarke Charles Howell III Y.E. Yang Retief Goosen J.J. Henry Troy Matteson Russell Henley Carl Pettersson Scott Piercy Camilo Villegas David Hearn James Hahn David Toms Justin Leonard John Rollins Blake Adams Danny Lee Russell Knox Steven Bowditch Michael Putnam Erik Compton Lucas Glover Woody Austin Mark Wilson Mike Weir
68-70—138 67-72—139 68-71—139 70-69—139 68-71—139 68-71—139 70-69—139 68-71—139 66-73—139 66-73—139 65-74—139 69-70—139 69-70—139 69-70—139 68-71—139 68-71—139 67-72—139 71-69—140 69-71—140 66-74—140 67-73—140 66-74—140 74-66—140 69-72—141 68-73—141 71-70—141 65-76—141 73-68—141 70-71—141 70-71—141 68-73—141 68-73—141 68-73—141 69-72—141 68-73—141 70-71—141 70-71—141
-2 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 E E E E E E +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1
MONDAY
at Dallas 7 p.m. WGN AM-720
PA 209 231 287 223 PA 146 106 218 190 PA 149 145 174 226 PA 175 231 187 236 PA 155 167 221 264 PA 166 197 172 208 PA 111 218 174 199
Thursday’s Game Minnesota 34, Washington 27 Sunday’s Games Detroit at Bears,. Monday’s Game Miami at Tampa Bay, 7:40 p.m. Open: Cleveland, Kansas City, N.Y. Jets, New England Thursday, Nov. 14 Indianapolis at Tennessee, 8:25 p.m. Sunday, Nov. 17 Baltimore at Bears, noon. Monday, Nov. 18 New England at Carolina, 7:40 p Open: Dallas, St. Louis
NFL INJURY REPORT DETROIT LIONS at BEARS — LIONS: OUT: WR Nate Burleson (forearm). DOUBTFUL: DE Ziggy Ansah (ankle), CB Bill Bentley (knee), T Corey Hilliard (knee). PROBABLE: RB Reggie Bush (knee), S Louis Delmas (knee), WR Calvin Johnson (knee), LB Travis Lewis (ankle), S Glover Quin (ankle). BEARS: OUT: LB Lance Briggs (shoulder), C Patrick Mannelly (calf), DT Jeremiah Ratliff (groin). DOUBTFUL: DE Shea McClellin (hamstring). PROBABLE: T James Brown (illness), LB Blake Costanzo (back), QB Jay Cutler (groin), TE Dante Rosario (ankle), CB Charles Tillman (knee). PHILADELPHIA EAGLES at GREEN BAY PACKERS — EAGLES: DOUBTFUL: LB Jake Knott (hamstring), QB Michael Vick (hamstring). QUESTIONABLE: CB Bradley Fletcher (pectoral). PROBABLE: S Patrick Chung (shoulder), WR Damaris Johnson (ankle), T Jason Peters (pectoral, shoulder), RB Chris Polk (shoulder, knee), DE Cedric Thornton (knee), C Julian Vandervelde (knee). PACKERS: OUT: QB Aaron Rodgers (collarbone). DOUBTFUL: LB Andy Mulumba (ankle). QUESTIONABLE: G T.J. Lang (concussion), LB Nick Perry (foot). PROBABLE: LB Clay Matthews (thumb), LB Mike Neal (knee), DT Ryan Pickett (knee).
COLLEGE TOP 25 SCHEDULE Saturday No. 1 Alabama vs. No. 10 LSU, 7 p.m. No. 3 Florida State at Wake Forest, 11 a.m. No. 7 Auburn at Tennessee, 11 a.m. No. 9 Missouri at Kentucky, 11 a.m. No. 11 Texas A&M vs. Mississippi State, 2:30 p.m. No. 14 Miami vs. Virginia Tech, 6 p.m. No. 15 Oklahoma State vs. Kansas, 3 p.m. No. 16 UCLA at Arizona, 9 p.m. No. 17 Fresno State at Wyoming, 9:15 p.m. No. 19 UCF vs. Houston, 6 p.m. No. 21 Wisconsin vs. BYU, 2:30 p.m. No. 23 Arizona State at Utah, 3 p.m. No. 24 Notre Dame at Pittsburgh, 7 p.m. No. 25 Texas Tech vs. Kansas State, 11 a.m.
WEDNESDAY
CLEVELAND 7 p.m. CSN AM-1000 at Iowa 7 p.m. WCUU
at Charlotte 6 p.m. WCUU
ON TAP TODAY TV/Radio AUTO RACING 10:30 a.m.: NASCAR, Sprint Cup, practice for AdvoCare 500, FS1 1130 a.m.: NASCAR, Nationwide Series, pole qualifying for ServiceMaster 200, FS1 1:30 p.m.: NASCAR, Sprint Cup, “Happy Hour Series,” inal practice for AdvoCare 500, FS1 3 p.m.: NASCAR, Nationwide Series, ServiceMaster 200, ESPN2 1:30 a.m.: NHRA, qualifying for Auto Club Finals, ESPN2 (delayed tape)
BOXING 8:30 p.m.:, HBO
COLLEGE FOOTBALL 11 a.m.: Kansas St. at Texas Tech, ABC 11 a.m.: Auburn at Tennessee, ESPN 11 a.m.: Penn St. at Minnesota, ESPN2 11 a.m.: TCU at Iowa St., FSN 11 a.m.: Missouri at Kentucky, ESPNU 11 a.m.: Iowa at Purdue, BTN 11 a.m.: Alabama Birmingham at Marshall, CSN 11:30 p.m.: James Madison at New Hampshire, NBCSN 2 p.m.: Southern Cal at California, Fox 2:30 p.m.: Nebraska at Michigan, ABC 2:30 p.m.: Mississippi St. at Texas A&M, CBS
2:30 p.m.: BYU at Wisconsin, ESPN 2:30 p.m.: UTEP at North Texas, CSN 2:30 p.m.: Illinois at Indiana, BTN, AM-560 2:45 p.m.: Tulsa at East Carolina, FSN 3 p.m.: Kansas at Oklahoma St., 3 p.m.: Cornell at Dartmouth, NBCSN 3 p.m.: North Carolina State at Duke, ESPNU 6 p.m.: Virginia Tech at Miami, ESPN 6 p.m.: Houston at UCF, ESPN2 6 p.m.: Texas at West Virginia, Fox 7 p.m.: LSU at Alabama, CBS 7 p.m.: Utah State at UNLV, ESPNU 7:07 p.m.: Notre Dame at Pittsburgh, ABC, AM-890 9 p.m.: UCLA at Arizona, ESPN 9:15 p.m.: Fresno St. at Wyoming, ESPN2
GOLF Noon: PGA Tour, The McGladrey Classic, third round, Golf Ch. 2:30 a.m.: European PGA Tour, Turkish Airlines Open, inal round, Golf Ch.
MEN’S COLLEGE BASKETBALL 3 p.m.: Grambling State at DePaul, AM-670 7 p.m.: Drake at Illinois Chicago, CSN 7:30 p.m.: Eastern Illinois at Northwestern, BTN
SOCCER 8:55 a.m.: Premier League, West Bromwich at Chelsea, NBCSN 11:30 a.m.: Premier League, West Ham at Norwich, NBC 1:30 p.m.: MLS, playoffs, conference championships, Leg 1, NBC
BETTING ODDS
Philadelphia at Cleveland, 6:30 p.m. Boston at Miami, 6:30 p.m. Orlando at Atlanta, 6:30 p.m. L.A. Clippers at Houston, 7 p.m. Golden State at Memphis, 7 p.m. Dallas at Milwaukee, 7:30 p.m. Portland at Sacramento, 9 p.m. Sunday’s Games San Antonio at New York, 11 a.m. Washington at Oklahoma City, 6 p.m. New Orleans at Phoenix, 7 p.m. Minnesota at L.A. Lakers, 8:30 p.m.
NBA PA 197 226 185 279
TUESDAY
EDMONTON 6:30 p.m. WGN AM-720
BASKETBALL
NFL NATIONAL CONFERENCE North W L T Pct PF Detroit 5 3 0 .625 217 Bears 5 3 0 .625 240 Green Bay 5 3 0 .625 232 Minnesota 2 7 0 .222 220 East W L T Pct PF Dallas 5 4 0 .556 257 Philadelphia 4 5 0 .444 225 Washington 3 6 0 .333 230 N.Y. Giants 2 6 0 .250 141 South W L T Pct PF New Orleans 6 2 0 .750 216 Carolina 5 3 0 .625 204 Atlanta 2 6 0 .250 176 Tampa Bay 0 8 0 .000 124 West W L T Pct PF Seattle 8 1 0 .889 232 San Francisco 6 2 0 .750 218 Arizona 4 4 0 .500 160 St. Louis 3 6 0 .333 186 AMERICAN CONFERENCE East W L T Pct PF New England 7 2 0 .778 234 N.Y. Jets 5 4 0 .556 169 Miami 4 4 0 .500 174 Buffalo 3 6 0 .333 189 South W L T Pct PF Indianapolis 6 2 0 .750 214 Tennessee 4 4 0 .500 173 Houston 2 6 0 .250 146 Jacksonville 0 8 0 .000 86 North W L T Pct PF Cincinnati 6 3 0 .667 217 Cleveland 4 5 0 .444 172 Baltimore 3 5 0 .375 168 Pittsburgh 2 6 0 .250 156 West W L T Pct PF Kansas City 9 0 0 1.000 215 Denver 7 1 0 .875 343 San Diego 4 4 0 .500 192 Oakland 3 5 0 .375 146
SUNDAY DETROIT Noon Fox AM-780, FM-105.9
FOOTBALL
PREPS FOOTBALL
TEAM
EASTERN CONFERENCE Central Division W L Pct Indiana 6 0 1.000 Milwaukee 2 2 .500 Detroit 2 3 .400 Bulls 2 3 .400 Cleveland 2 4 .333 Atlantic Division W L Pct Philadelphia 4 2 .667 New York 2 3 .400 Brooklyn 2 3 .400 Toronto 2 4 .333 Boston 2 4 .333 Southeast Division W L Pct Miami 4 2 .667 Charlotte 3 3 .500 Orlando 3 3 .500 Atlanta 2 3 .400 Washington 2 3 .400 WESTERN CONFERENCE Southwest Division W L Pct San Antonio 5 1 .833 Houston 4 2 .667 New Orleans 3 3 .500 Dallas 3 3 .500 Memphis 2 3 .400 Northwest Division W L Pct Oklahoma City 4 1 .800 Minnesota 4 2 .667 Portland 3 2 .600 Denver 1 4 .200 Utah 0 6 .000 Pacific Division W L Pct Golden State 4 2 .667 Phoenix 4 2 .667 L.A. Clippers 3 3 .500 L.A. Lakers 3 4 .429 Sacramento 1 4 .200
GB — 3 3½ 3½ 4 GB — 1½ 1½ 2 2\ GB — 1 1 1½ 1½ GB — 1 2 2 2½ GB — ½ 1 3 4½ GB — — 1 1½ 2½
Friday’s Games Bulls 97, Utah 73 Boston 91, Orlando 89 Philadelphia 94, Cleveland 79 Indiana 91, Toronto 84 Washington 112, Brooklyn 108, OT New York 101, Charlotte 91 Oklahoma City 119, Detroit 110 Minnesota 116, Dallas 108 New Orleans 96, L.A. Lakers 85 San Antonio 76, Golden State 74 Phoenix 114, Denver 103 Portland 104, Sacramento 91 Saturday’s Games Utah at Toronto, 6 p.m. Indiana at Brooklyn, 6:30 p.m.
BULLS 97, JAZZ 73 UTAH (73) Jefferson 3-12 1-2 8, Favors 3-10 4-6 10, Kanter 4-11 0-0 8, Tinsley 1-3 0-0 2, Hayward 5-15 4-5 15, Lucas III 3-9 0-0 9, Gobert 1-2 2-6 4, Burks 3-13 3-4 10, Williams 1-5 0-0 3, Harris 1-3 2-2 4, Clark 0-2 0-0 0. Totals 25-85 16-25 73. CHICAGO (97) Deng 7-9 5-5 19, Boozer 7-11 4-6 18, Noah 6-9 2-4 14, Rose 3-8 5-5 12, Butler 2-5 0-0 5, Gibson 5-13 2-4 12, Dunleavy 4-7 0-0 9, Hinrich 1-2 0-0 2, Mohammed 3-6 0-1 6, Snell 0-1 0-0 0, Murphy 0-1 0-0 0, Teague 0-0 0-0 0, James 0-0 0-0 0. Totals 38-72 18-25 97. Utah Chicago
18 22 16 17 — 73 30 21 27 19 — 97
3-Point Goals–Utah 7-20 (Lucas III 3-4, Hayward 1-2, Williams 1-3, Burks 1-3, Jefferson 1-4, Favors 0-1, Clark 0-1, Tinsley 0-2), Chicago 3-8 (Dunleavy 1-1, Rose 1-2, Butler 1-4, Hinrich 0-1). Fouled Out–None. Rebounds–Utah 54 (Gobert 12), Chicago 56 (Deng 11). Assists–Utah 18 (Hayward 5), Chicago 26 (Deng 9). Total Fouls–Utah 21, Chicago 24. Technicals–Utah defensive three second, Chicago defensive three second. A–21,946 (20,917).
11 15 16 18 21 22 24 25 27 30
Opponent November CLEVELAND at Toronto INDIANA CHARLOTTE at Denver at Portland at L.A. Clippers at Utah at Detroit at Cleveland
Time 7 p.m. 6 p.m. 7 p.m. 7 p.m. 9:30 p.m. 9 p.m. 2:30 p.m. 8 p.m. 6:30 p.m. 6:30 p.m.
HOCKEY NHL Friday’s Games Toronto 2, New Jersey 1, SO Winnipeg 5, Nashville 0 Colorado 4, Calgary 2 Anaheim 6, Buffalo 2 Saturday’s Games Blackhawks at Dallas, 8 p.m.. Washington at Phoenix, 8 p.m. Vancouver at Los Angeles, 10 p.m. Sunday’s Games Edmonton at Blackhawks, 7:30 p.m. N.Y. Islanders at Montreal, 6 p.m. Nashville at New Jersey, 7 p.m. Florida at N.Y. Rangers, 7 p.m. San Jose at Winnipeg, 8 p.m. Washington at Colorado, 8 p.m. Vancouver at Anaheim, 8 p.m.
AHL Friday’s Gmes St. John’s 5, Manchester 2
Providence 8, Hartford 5 Portland 5, Worcester 1 Adirondack 3, Springfield 0 Binghamton 3, Rochester 2, OT Albany 6, W-B/Scranton 5 Grand Rapids 6, Hamilton 1 Utica 3, Lake Erie 2 Syracuse 2, Norfolk 1 Rockford 3, Iowa 1 Texas 7, Milwaukee 4 Saturday’s Games Wolves at Charlotte, 6 p.m. Adirondack at Albany, 4 p.m. Manchester at St. John’s, 5 p.m. Bridgeport at Hershey, 6 p.m. Providence at Worcester, 6 p.m. Rochester at Binghamton, 6:05 p.m. Syracuse at Norfolk, 6:15 p.m. Iowa at Rockford, 7 p.m. Oklahoma City at San Antonio, 7 p.m. Milwaukee at Texas, 7 p.m. Toronto at Abbotsford, 9 p.m. Sunday’s Games Utica at Hamilton, 2 p.m. Adirondack at Bridgeport, 2 p.m. W-B/Scranton at Springfield, 2 p.m. Portland at Worcester, 2 p.m. Hartford at Providence, 2:05 p.m. Binghamton at Hershey, 4 p.m. Milwaukee at San Antonio, 4 p.m. Toronto at Abbotsford, 6 p.m.
AUTO RACING.
College Football FAVORITE PTS O/U UNDERDOG Iowa 15 (45) at Purdue W. Kentucky 6 (57½) at Army at Cincinnati 9 (65½) SMU at Duke 9 (57) NC State at East Carolina 17 (52½) Tulsa at Indiana 9 (78) Illinois TCU 7½ (46) at Iowa St. Florida St. 34½ (55) at Wake Forest at Marshall 24 (67) UAB at Miami 6½ (44) Virginia Tech at Minnesota 2½ (48) Penn St. at Maryland 5½ (54½) Syracuse Missouri 13½ (57) at Kentucky at N. Carolina 13½ (51½) Virginia at Florida 10 (42½) Vanderbilt W. Michigan 2½ (58½) at E. Michigan at UTSA 9 (51) Tulane Fresno St. 9½ (79) at Wyoming at Texas Tech 2½ (59½) Kansas St. at Wisconsin 8 (55½) BYU at Mississippi 17 (53½) Arkansas at Colorado St. 9 (65) Nevada at Washington 28 (60½) Colorado Texas 6 (56) at West Virginia Arizona St. 6½ (63½) at Utah at Michigan 6½ (57½) Nebraska at Navy 17 (53) Hawaii at North Texas 25 (57) UTEP at Oklahoma St. 31 (53½) Kansas Southern Cal 16½ (56) at California Notre Dame 4½ (51) at Pittsburgh at Texas A&M 19 (67) Mississippi St. Boston College 24½ (60½)atNewMexicoSt. Utah St. 14½(56½) at UNLV at Middle Tenn. 18 (48½) FIU at La.-Monroe 3½ (57) Arkansas St. atLouisianaTech 16½ (52) Southern Miss. Auburn 7½ (55) at Tennessee at UCF 10½ (64) Houston at Arizona 1 (56½) UCLA at Alabama 12½ (55) LSU at San Jose St. 6½ (56) San Diego St. NFL PTS O/U UNDERDOG Sunday at Bears Pk (52½) Detroit at Tennessee 12½ (41) Jacksonville at Green Bay 1 (47) Philadelphia at Pittsburgh 3 (43½) Buffalo at N.Y. Giants 7 (43½) Oakland at Indianapolis 9½ (44) St. Louis Seattle 5 (44½) at Atlanta Cincinnati 1½ (44) at Baltimore at San Francisco 6 (43) Carolina at Arizona 2½ (41) Houston Denver 7 (58) at San Diego at New Orleans 6½ (54) Dallas Monday Miami 2½ (41) at Tampa Bay FAVORITE
BULLS SCHEDULE Date
GLANTZ-CULVER LINE.
NCAA Basketball FAVORITE LINE NBA FAVORITE LINE O/U UNDERDOG at Toronto 7 (189½) Utah at Atlanta 6½ (201) Orlando at Brooklyn 4 (188½) Indiana at Cleveland 10½ (204) Philadelphia at Miami 15 (194½) Boston at Houston 4 (213) L.A. Clippers at Memphis 4 (199) Golden State Dallas 3½(203½) at Milwaukee at Sacramento Pk (202½) Portland FAVORITE Blackhawks at Philadelphia at Ottawa at Boston at Detroit Minnesota at Columbus at St. Louis at Phoenix at Los Angeles
NHL LINE UNDERDOG -150 at Dallas -160 Edmonton -200 Florida -180 Toronto -130 Tampa Bay -130 at Carolina -125 N.Y. Islanders -135 Pittsburgh -140 Washington -130 Vancouver
LINE +130 +140 +170 +160 +110 +110 +105 +115 +120 +110
SOCCER MLS PLAYOFFS CONFERENCE CHAMPIONSHIP Eastern Conference Kansas City vs. Houston Leg 1 — Saturday, Nov 9: Kansas City at Houston, 2:30 p.m. Leg 2 — Saturday, Nov. 23: Houston at Kansas City, 7:30 p.m. Western Conference Portland vs. Real Salt Lake Leg 1 — Sunday, Nov. 10: Portland at Real Salt Lake, 9 p.m. Leg 2 — Sunday, Nov. 24: Real Salt Lake at Portland, 9 p.m. MLS CUP Saturday, Dec. 7: at higher seed, 4 p.m.
Northwest Herald / NWHerald.com
Page C6 • Saturday, November 9, 2013
Brilliance Honda November Sales Event!
0
.9%
Final 2013 Honda Inventory... Get ’em while they last.
2013 Honda Civic Sedan LX
#P2200 Pre-driven
60
*
New 2013 Honda CR-V LX AWD
New 2013 Honda Accord LX Lease Special!
Lease Special!
Automatic
Automati Automatic
Lease for
15,999
Months On All New 2013 Accords, 2014 Accords, 2014 Odysseys & 2014 CR-V’s
New 2013 Honda Civic LX Lease Special!
149
$
/mo
60
X
$
5 at this Price!
1
Financing
Months On All New 2013 Honda Civics, Crosstours, CR-V’s, Pilots, Fits & Accord Coupes++
Automatic Transmission Estimated MPG 25 City/ 36 Highway. way.†
.9% APR Financing for
APR
^
36 month lease with only $999 Down!^
Lease for
199
$
/mo
Lease for
^
$
219
/mo^
36 month lease with only $999 Down!^
36 month lease with only $999 Down!^
★ W Terra Cotta Ave
CRYSTAL
ia St
680 W. Terra Cotta Ave., Crystal Lake % 815.459.6400
in irg NV
At the Intersection Route 14 and Route 176
Like L ike Uss On: U On:
967.! 81;"!) /13064+("<064 *)''65+*$5 % 96=;"064 *65+-$5 # 9.":<2. 81;"!) /13064+("<064 -)&'65+*$5 % 96=;"064 ,65+&$5 ^Civic: $999 down payment, first months payment due at signing, security deposit waived. Accord: $999 down payment, first months payment due at signing, security deposit waived. CR-V: $999 down payment, first months payment due at signing, security deposit waived. Add tax (based on MSRP), title, license and doc fee, to qualified buyers with approved credit. Residuals: Civic LX= $11,260, 12,000 miles per year, overage charges may apply. Accord LX=$12,798, 12,000 miles per year, overage charges may apply. CR-V LX=$15,765, 12,000 miles per year, overage charges may apply. *On select models to qualified buyers. 1.9% APR for 60 months is $28.16 per $1000 financed. ++ 0.9% for 60 months to qualified buyers. $17.05 per $1,000 financed.†Based on 2012 EPA mileage estimates, reflecting new EPA fuel economy methods beginning with 2009 models. Use for comparison purposes only. Do not compare to models before 2009. Your actual mileage will vary depending on how you drive and maintain your vehicle for all advertised leases. With a valid Honda APR, lease or leadership purchase plan with HFS. Certain restrictions apply. See dealer for details. Photos are for illustration purposes only and may not reflect actual vehicles. Vehicle availability based at press time and all vehicles subject to prior sale. Dealership is not liable for price misprints or typographical errors. Manufacturer incentives subject to change without notice and may affect dealers selling price. Offers expire 11/30/13.
View Our New and Used Inventory at:
Use your smartphone to scan this code.
BrillianceHonda.com
Business
PAGE E1 APPEARS INSIDE TODAY
Page E3
Breaking news @
Business Journal editor: Brett Rowland • browland@shawmedia.com
THE MARKETS
Saturday, November 9, 2013 Northwest Herald
8BUSINESS ROUNDUP
HELPING COMMUNITIES IN MANY WAYS 167.80
Shah Center to offer Lean Office course
15761.78
61.90 3919.23
23.46 1770.61
OIL
$94.38 a barrel +0.18
THE STOCKS Stock
Abbott Labs AbbVie AGL Resources Allstate
Apple AptarGroup AT&T Bank of Montreal Baxter Berry Plastics Boeing Caterpillar Office Depot Pepsi Pulte Homes Safeway Sears Holdings Snap-On Southwest Air. Supervalu Target Twitter United Contint. Wal-Mart Walgreen Waste Mgmt. Wintrust Fincl.
Change
38.12 48.03 47.58 54.12 520.56 64.25 35.17 69.49 65.13 19.77 133.49 84.24 77.81 40.05 48.18 63.84 19.39 39.67 28.34 92.73 47.53 16.85 36.66 1016.03 32.05 179.99 53.96 57.03 52.73 18.26 97.01 37.78 13.31 63.12 5.04 85.85 16.85 33.02 56.72 104.96 17.69 6.68 65.11 41.65 35.36 77.96 59.7 44.16 44.77
+0.48 +0.79 -0.26 +1.18 +8.07 +0.84 +0.06 +0.26 -0.09 +0.05 +1.98 +0.59 +3.15 +0.22 +0.94 -1.10 +0.08 +1.00 -0.22 +0.77 -0.03 +0.30 +0.74 +8.08 +0.06 -0.01 +2.31 +0.49 -0.71 +0.46 -0.19 +0.28 +0.29 +0.63 +0.19 +0.55 -0.66 -1.01 +0.34 +1.12 +0.12 +0.06 +0.29 -3.25 +1.37 +0.45 +0.50 +0.78 +1.51
COMMODITIES Metal
Gold Silver Copper
1287.30 21.49 3.258
Grain (cents per bushel) Close
Corn Soybeans Oats Wheat
426.75 1306 334.50 649.75
Livestock
Live cattle Feeder cattle Lean hogs
132.45 164.70 88.225
Change
-21.20 -0.172 + 0.0095 +6.25 +27.25 -4.50 -3.25 Change
+ 0.775 -0.425 + 0.675
To sign up for the Northwest Herald Business Update weekly email newsletter, select Business Update at NWHerald.com/newsletter.
Follow all the latest local and national business news on Twitter @NWHeraldbiz
Nonprofits’ impact beyond employment Officials: Organizations offer economic benefits By EMILY K. COLEMAN ecoleman@shawmedia.com Programs offered by Family Alliance give seniors with Alzheimer’s a place to go during the day, giving their caregivers the ability to stay in the workforce, the nonprofit’s director said. Government subsidies for early childhood centers such as the Hearthstone Early Learning Center require parents to be working or attending school, said Terry Egan, Hearthstone Communities’ chief executive officer and president. The Home of the Sparrow estimates that over 90 percent of the women who graduate from its programming are successful in staying employed and maintaining housing, Executive Director John Jones said. The people the Pioneer Center for Human Services helps might be recipients of welfare, not have jobs and not pay taxes, but the center has a high success rate in breaking that cycle, president and CEO Patrick Maynard said. These services give nonprofits a larger impact than just the number of employees they have and the dollars they spend, their top officials said. A recent report released by Donors Forum, a nonprofit association, highlighted the economic footprint left by Illinois nonprofits. Nonprofits employ more than 523,000 people in Illinois with a combined payroll of $19.7 billion, according to the report. That’s nearly 9 percent of the state’s workers, more than construction, transportation and real estate combined. In McHenry County, nonprofits employ 5,776 people, or about 3.64
See NONPROFITS, page E2
Abiding Spirit Center offers services for vets CRYSTAL LAKE – Abiding Spirit Center and Acupuncture & Oriental Medicine is offering pay-as-you-wish treatments to veterans on Monday, which is Veterans Day. Veterans can schedule an appointment by calling the center at 815-363-1390. For information, visit the center, 1540 Carlemont Drive, Crystal Lake, or.
Yumz Frozen Yogurt to give discount to vets. Kyle Grillot – kgrillot@shawmedia.com
A recently released report from the Donors Forum found that nonprofit organizations employ more than 523,000 people in Illinois and have a combined payroll of $19.7 billion. Assistant teacher Lydia Patnaude of Woodstock (right) works with Sophia Carrion inside the classroom for 15-month-olds to 2-year-olds at the Hearthstone Early Learning Center in Woodstock.
Top 5: Largest nonprofit organizations in McHenry County by employees Centegra Health System Pioneer Center for Human Service Hearthstone Communities Sage YMCA of Metro Chicago McHenry County Youth Service Bureau (Pioneer Center)
Employee 2,914 319 215 100 70
Volunteers Annual Operating Budget 404 $455 million 170 $14.5 million 300 $10 million 100 not provided 0
$1.9 million
Source: 2013 data submitted to the Northwest Herald by area nonprofits
USDA: Corn harvest hits record 13.9B bushels DES.
– From local and wire reports
Change
Stay connected
Kyle Grillot – kgrillot@shawmedia.com
A recently released report from the Donors Forum found that nonprofits employ nearly 9 percent of the state’s workers, and that impact is even larger in the education sector. Teacher Jayne Grask of Woodstock (left) works with Emma Morales, Will Rojas and Jacob Simon at the Hearthstone Early Learning Center in Woodstock.
McHENRY – The McHenry County College Shah Center is offering an “Introduction to a Lean Office: Creating a Workplace of Precision and Speed” course from 8 a.m. to 1:30 p.m. Friday at the Shah Center, 4100 W. Shamrock Lane in McHenry. This program will teach the organizational commitment necessary to succeed at improving manufacturing, office and administrative processes; the critical value of streams to act upon to experience positive impact on customers; mapping of current and future practices as well as relevant metrics; how to eliminate waste and improve office and administrative processes; and how to level the demand for and create a continuous flow of office administrative work. The course is $159 and participants may use Course ID: NTE S20 001 when registering. To register, call the MCC Registration Office at 815-4558588. For information, contact the Shah Center at 815-4558593 or shahcenter@mchenry. edu.
Hearthstone expands independent living facilities By BRETT ROWLAND browland@shawmedia.combed.
See HEARTHSTONE, page E2
Lathan Goumas – lgoumas@shawmedia.com
Carol Baker sits in her living room at her home of six years in the Serenity Creek development in Woodstock. The development recently was bought by Hearthstone Communities, which also operates a senior living campus in Woodstock.
BUSINESS
Page E2 • Saturday, November 9, 2013
Tweet prompts apology
Northwest Herald / NWHerald.com
What makes for a successful business? What criteria does a business have to meet in order for it to be successful? What differentiates successful business ventures from the large percentage of startups that fail? I truly believe that it comes down to passion – a double-edged quality. Too often passionate entrepreneurs delve headfirst into a venture before thinking it through. Before taking that plunge, clarify your reasons and your goals. Knowing why you’re doing this and having a clear picture of what you hope to achieve is just a starting point. Understand your entrepreneurial personality. Focus on ways to maximize your skills, assets, resources and relationships. To turn your passion into profits, emphasize the market. Focus on your business relative to the customers you serve by knowing your markets. Understanding the needs and prefer-
Home Depot acts after racist content goes out The ASSOCIATED PRESS NEW YORK – Home improvement retailer.
CHAMBER NEWS Shari Gray ences of your customers enables you to prioritize your customer’s experience and perception of value. Passionate entrepreneurs tend to have rose-colored plans and overestimate beginning sales and underestimate costs. Write a business plan that makes financial sense for your current needs and future goals of your business. It is imperative you have a clear picture of how your business will come together in a way that is profitable over time. Don’t see what you want to see and rely on “feeling good” about the direction your business is going in as your only measure of success. Oftentimes the reason most
startups fail is because they run out of money and time. There are many sources that offer free advice about business plans, financing, selling and marketing. You can contact the U.S. Small Business Administration as well as the Service Corps of Retired Executives. Both of these organizations are a wealth of information for startup businesses and existing businesses. Your local Chamber of Commerce also provides assistance and offers networking opportunities with other like-minded businesspeople. The Woodstock Chamber increases your visibility, has great business resources, and your membership invests in your community. Whether you’re contemplating starting a business or have already started the process, congratulations! You are among an elite group of entrepreneurs, and it’s an exciting time as you start your journey.
Welcome and congratulations to our newest Chamber members: Porkies, Isabel’s Family Restaurant, The Sugar Circle, Helping Paws Animal Shelter, OWC Pro IT, Young Ones Yoga, Best Western Woodstock Inn, Woodstock Harley-Davidson, Directors Financial Group, Valuentum Securities, Video Light Sound, Jones Insurance Services, 1st Family Home Healthcare, P.E.P. Processing, JCF Real Estate, Culvers of Woodstock, Girl Scouts of Northern Illinois, D&D Plumbing, HyperStitch, Creative Letter & Office Services. Please join Re/Max Plaza as it celebrates the grand opening of its new Woodstock office with an all-member Chamber mixer from 5 to 7 p.m. Nov. 21 at 112 N. Benton St.
• Shari Gray is executive director of the Woodstock Chamber of Commerce & Industry.
SAC Capital pleads guilty in N.Y. in $1.8 billion fraud case deal billionaire Steven A. Cohen had reached the deal that also required it to shut down its operations to outside investors. But Judge Laura Taylor Swain did not immediately accept the plea, saying she’d wait until a probation report
settle charges that it allowed, if not encouraged, insider trading to occur for more than a decade. The plea came in U.S. District Court in Manhattan four days after the government announced that the once influential hedge fund owned by
The ASSOCIATED PRESS NEW YORK – SAC Capital Advisors pleaded guilty to criminal fraud charges Friday, satisfying a deal with the government that requires the Connecticut-based hedge fund to pay a record $1.8 billion to
Growth comes despite effects of U.S. downturn For-profit businesses also are taking advantage of governments’ emphasis on the bottom line, moving into areas that are traditionally the territory of nonprofits, Maynard said. But as the government shrinks its role in various areas, Larson expects nonprofits to have to play a bigger role, stepping up to provide the cut services. She’s optimistic that nonprofits will continue to play a “tremendous role” in health care and social services and that donations and volunteer dollars will continue to support the growing missions. Nonprofits also have become a lot more sophisticated at addresssing needs and raising revenue, Jones said. “A lot more partnering and relations are being developed between agencies and groups,” Eesley said, adding that larger health systems are combining to address capital needs and excess capacity.
which will create six positions to start, Executive Director Kim Larson said. It employs 50 people, according to submitted data. Those employees go out, buy groceries and pay their bills, multiplying a nonprofit’s effect as an employer, Maynard said. The growth is despite the challenges raised by the 2008 economic downturn, which led to a dropoff in charitable giving (it’s been on the rise for the past three, hitting 2007 levels in 2012) and cuts or delayed payments from the state and federal government. The impact hasn’t been the same for all nonprofits. The senior living side of Hearthstone Communities was hit with some cuts, but the Early Learning Center hasn’t really been affected at all, Egan said. Nonprofit leaders are mixed in their expectations for the future and how these changes will play out.
• NONPROFITS Continued from page E1 percent of the county’s workers in 2010, according to data compiled by Donors Forum. About two-thirds of those workers are employed in the education, health care and social assistance sectors. Those numbers don’t surprise Centegra Health System CEO and president Mike Eesley. With 3,620 employees, Centegra is the county’s largest employer, according to 2013 numbers submitted to the Northwest Herald. The next closet is Walmart with 2,400. Centegra is also set to add another location in Huntley, which will add an additional 1,000 positions and employ 800 people during the construction, Eesley said. Centegra isn’t the only organization looking to expand. Woodstock-based Family Alliance is adding another location, its second, in Huntley,
is made. She set a sentencing date for March 14, assuming that.
Open house set next week Open house
• HEARTHSTONE Continued from page E1 .
BRIDGE Crossword ACROSS may provide closure in a tragedy 8 Discarded 15 City named for Theodore Roosevelt’s vice president 17 Word search technique? 18 Webby Award winner who accepted saying “Please don’t recount this vote” 19 With 11-Down, animal called “stubbin” by locals 20 Nascar stat that rises under caution flags 21 Diddly 22 Opening in the computer business? 23 Bad thing to lose 24 Flights 25 Taste makers?
26
1 It
27 28 29 30 35 36 37 39 42 43 44 45 46 47 48 49 50 53
Has it bad for, so to speak -i relative Largest city in Moravia Mob member, informally Morale Second in command? Cloverleaf section Flat top Blended dressing? Shutter shutter Literally, “I do not wish to” Sauna exhalations Solomonic Chewed the fat Watson’s creator Lowest of the low? Prankery 1965 Beach Boys hit Mission
ANSWER TO PREVIOUS PUZZLE S C A L D E D
A H I T U N A
N U R S E R Y
E N C A M P S
T O O S O O N
A T E I N T O
T A N A N N E L T A X I G U M T S O O N N L I L Y K E Y I L E D E S I N I V A M O S T E R O M A C C O N E
N O S S H L O O W S
E X P O S
P D I Q N C I E S E B A A M T O H A
T F L I X I D A T E R A Y E R E A M O T W I X G R A Z E L A Y E D I P T E S T S Z Z T O P E U R E S N N E I S T A D R P E D O I R D O S
54
55
Jason Mraz song that spent a record 76 weeks on Billboard’s Hot 100 Outcries
DOWN 1 Outgoing 2 Lot
arrangement
Edited by Will Shortz 1
2
4
5
6
7
15
8
9
10
11
12
13
14
16
17 18
19
21
20
22
24
23
25
27
26
28
3 Draws 4 Some
refrigerants 5 Reinforcement pieces 6 Mantel piece 7 Nissan bumpers? 8 Annual event since 1929, with “the” 9 Hard to pick up 10 Cigarette paper source 11 See 19-Across 12 Author of 1980’s “The Annotated Gulliver’s Travels” 13 Macedonia’s capital 14 “El día que me quieras” and others 16 Large monitors 22 Abandon one’s efforts, informally 23 “The Hound of the Baskervilles” backdrop 25 It’s around a cup 26 1 Infinite ___ (address of Apple’s headquarters)
3
No. 1005
30
29
31
32
35 39
40
33
36
41
37
42
44
46
48
50
38
43
45
47
34
49
51
52
53 54
55
PUZZLE BY BYRON WALDEN
28 29 31 32 33 34 38
Dover soul Force in red uniforms: Abbr. Course data Palliate Hit hard, as in an accident Tip used for icing They will be missed
39 40 41 42 43
45
46
Lightly hailed? Major report “Yowza!” Hound Dresden decimator of 1945 Something beyond the grate divide? Herod’s realm
48
1879’s Anglo___ War
49
“Fantastic Mr. Fox” author
51
War on Poverty agcy.
52
Advisory grp. that includes the drug cz.
To subscribe to the Northwest Herald, call (815) 459-8118.
By PHILLIP ALDER Newspaper Enterprise Association
After the opener bids one of a suit and the next player makes a takeout double, if the responder redoubles, it shows at least 10 high-card points and often a desire to try to penalize the opponents. So, if fourth hand (the advancer) bids a suit, the opener (unless he can double with length there) typically passes to give his partner a chance to double. In contrast, what does it mean if the opener bids immediately, in front of his partner? The answer is that the opener has a minimum or subminimum opening bid with offensive, not defensive, values. An example is the North hand in the diagram. He has only 11 high-card points and a hand that is built for declarer play, not defense. South, a tad disappointed, signs off in three no-trump. West leads the heart three, and East puts in the eight. After winning with his king, how should declarer proceed? South starts with only ive top tricks: one spade, two hearts and two diamonds. However, he can hope to win at least six diamond tricks, if not seven. But he must be careful not to play a diamond
to dummy’s jack. Then he would fall foul of the foul 4-0 split. Instead, declarer must inesse dummy’s nine on the irst round. Here, he ends with 11 tricks: one spade, two hearts, seven diamonds and one club. But even if East could take the irst diamond trick, the contract would be safe. Finally, note that many experts play an immediate jump rebid by opener also indicates a bare 11 or 12 points, with a hand having even more winners and scant defensive values.
Contact Phillip Alder at pdabridge@prodigy.net.
CLASSIFIED
Northwest Herald / NWHerald.com
MECH. TYPE PERSON FOR FARM EQUIP. 815-923-2660 MUST HAVE DRIVERS LICENSE.
ANIMAL CARE Full Time Must have open availability. Weekends & holidays. Physical labor involved, including outside time walking dogs. Apply online at: Online Application Page Phone: 847-961-5541 Animal House Shelter, Huntley
Animal Shelter Worker Work with Cats, Dogs and Farm Animals at a no kill animal shelter. Must be dependable, like animals and like to clean. Apply in person between 11am-4pm Mon.-Sun.
St. Francis Animal Shelter
12300 116th St. Kenosha, WI. Just over IL/WI border Automotive
Accounting Clerk McHenry County's #1 Dealership has an opening for a full time accounting clerk. If you have previous automotive experience, ADP knowledge and strong computer skills, this may be the job for you. We offer a comprehensive benefits package and a pleasant work environment. Apply in person at: Gary Lang Auto Group in McHenry or e-mail your resume to: lpipala@garylangauto.com
1107 South Rte. 31 McHenry, Illinois
QUALITY CONTROL COORDINATOR Manufacturing company is seeking an experienced Quality Coordinator. Must possess leader skills, computer skills, knowledge of plastics, several quality measuring devices, quality system software, statistical processes, and excellent communication skills. Bilingual a plus. Fax resume: 847-247-9803
Sales Manager - FT for Gun Range On Target Range in Crystal Lake is seeking a Sales Manager. Candidate will be supervising 20+ sales associates, arranging schedules, handling purchasing, receiving and inventory and overseeing the completion of 4473's. This is a fast-paced, high energy environment. Candidate must have knowledge of ATF compliance regulations and must possess strong communication and leadership skills. Mgmnt exp. in retail sales pref'd. Apply to: Judy@ontargetsite.com
ESTIMATOR Excavating and Demolition Contractor looking for experienced estimator. Pay based on previous field experience. 847-878-9743
Injection Molding Maintenance Technician Must have experience with preventive maintenance, troubleshooting of Injection Molding machines and Support Equipment. Must have min. of 3 years of experience in this industry. Excellent benefits package. Apply in person or fax resume:
Chemtech Plastics, Inc. 765 Church Road Elgin, IL 60123 Fax: 847-742-7968 EOE
Live-In Caregivers Needed Looking for Experienced & Loving Live-Ins. Dementia Experience a Plus! TO APPLY: VA175.ersp.biz/employment Visiting Angels of Crystal Lake Serving McHenry County HORSE STALL CLEANING $9/hr. Wauconda area. Mon-Fri. 3-4 hrs/day. 3-5 days/week. 847-452-2201
Healthcare LOOKING FOR Compassionate & Caring... !!!!!!!!!!!
CNA's RN's LPN's
Injection Molding Technician
Dietary Position - PT !!!!!!!!!!!!! APPLY IN PERSON TODAY:
Perfect Shutters Attn: HR, 12213 Hwy 173 Hebron, IL 60034 McHenryCountySports.com is McHenry County Sports
CRYSTAL LAKE 1BR, 2nd FLOOR
Excellent Pay & Benefits. Fax resume: 815-479-1280
Small building, $800/mo. No pets/ smoking, heat incl, near metra. Garage available. 815-344-5797
! RN / LPN !
CRYSTAL LAKE 2 BEDROOM
All shifts. Pediatric exp. Wknds. McHenry & Kane Co. 815-356-8400
Medical Transcription company has full and part time positions available. Experience preferred but will train the right candidate. Send resume to kcsemploy1@sbcglobal.net.
Crystal Lake 2 Bedroom FREE HEAT! Brand new carpet. Close to lake, no pets. 815-690-1614 ~ 708-436-0035 Crystal Lake 2 Bedroom, 1 Bath Laundry, garage, no pets. ½ block from metra, $900/mo. 847-639-3224 Crystal Lake Dowtown Quiet, Large BEAUTIFUL Modern, Open Concept 1BR. W/D, parking, $800/mo. Available Now! 815-482-1600
CRYSTAL LAKE Large & Spacious 2BR
Huntley ~ Del Webb Caregiver Needed. Live in or out, must have own trans, all options can be discussed. Leslie 224-277-7814
Caregiver, Exp Polish Nurse with green card, exc ref, speaks English. Will work 24/7. Call Zofia 224-276-9686 or 815-263-0943
First floor, $850/mo. Heat, gas, water, D/W incl. Pets extra. 847-707-3800
FOX LAKE 1 BR, Laundry on-site, no pets, Sect 8 OK, $690/mo + sec. 847-812-9830 FOX LAKE ~ GOOD VALUE! Very lrg 1BR, dining area, balcony, strge & lndry in building, no dogs, utils incl. except elec., $725/mo. Agent Owned 815-814-3348
MAILBOX & POST
Anything to do with Wood We can Fix or Replace Doors and Windows Sr. Disc. 815-943-4765
POLISH LADY will clean your Home/Office. FREE ESTIMATES.
HARVARD AREA Huge 3BR, 2BA loft apt. Quiet. Frplc, W/D, C/A. Fish/Swim. Pets ok. $1025/mo. 815-648-2716
ALWAYS INVESTIGATE BEFORE INVESTING ANY MONEY
Ampac has an immediate position available for an experienced Maintenance Mechanic.
Near Square, $750/mo + utilities. No pets/smoking. 815-338-1742 WOODSTOCK – 2BR, 1BA, 1st Flr. 118 Donovan. Spacious, Kitch appliances incl, Laundry hkups. Pets negot. $765/mo+$1,000sec. 815-382-0015 WOODSTOCK 2BR. Rogers Hall. $800-$825/mo. Move-in special: $300 off 1st mo. Offer good thru 12/31. NO PETS! 815-482-4909
Elevator Building 815-334-9380
LOOKING FOR A JOB?
Contact the Better Business Bureau - or Federal Trade Commission ALGONQUIN PIZZARIA. Established, west of the River. Reasonable terms, owner will train, includes all business equip. $72,500. Call Tony Bellino,Re/Max of Barrington 847-343-2342.
NEWSPAPER DELIVERY Earn up to $1000 A Month! Looking for Contractors to deliver newspapers early mornings 7 days per week. Routes now available in McHenry County. Please Call 815-526-4434
Find the job you want at:
NWHerald.com/jobs
ISLAND LAKE 2 BEDROOM Quiet building, no pets. $825 + sec. 847-526-4435
Island Lake Luxury Apt.
CAT ~ GREY TIGER
Crystal Lake-Nice 4BD ranch home w/full fin bsmt. 1 flr lndry,lrge deck. Prairie Ridge HS. $1400/mo. 6 mo lease ok. B&W 815-347-7452
Woodstock: 2BR apt. $800/mo.+sec. dep Roberto 773-317-3364
2 car garage, deck, very nice neighborhood, $1400/mo. 815-337-6935 ~ 815-546-1033
HEBRON SHARP 2BR CONDO'S
Appls, W/D, patio & deck, prvt entrance. Starting @ $745-$875. Garage avail. 815-455-8310
Huntley Newer 2BR, 1BA TH Sun City. Exc cond, attach garage. $1140/mo. 708-456-1620
Lake In The Hills Beautiful 2BR Condo ~ 2 bath, D/W, A/C, W/D in unit, garage, tennis, basketball. $1000/mo. 224-633-5049
Woodstock: 3BR, 1.5BA, TH, full bsmt, 2 car gar. w/opnr, concrete patio, yrd, full kitch. w/ all appl., no pets $1200/m 630-514-4956
MARENGO 2BR DUPLEX
1.5BA, 1st floor laundry room. basement, 2 car garage. $1050 + sec. 815-568-6311
Woodstock -1BR, Den, Utility Rm Close to Sq, living rm, kit, no pets/ smoking. $725/mo + utilities, sec + ref required. 815-338-1734
WOODSTOCK 3 BEDROOM 1.5 Bath, A/C, Stove, Refrigerator, Garage, No Pets. Broker Owned. 847-683-7944 HURRY!!
McHenry. 3BR, 1BA. Newly remodeled. Quiet neighborhood. All appls, W/D. Avail now. No pets. $1000/mo. 704-239-3994 McHenry. 3BR, 2BA, tri level in Fox Ridge, fenced yrd, sidewalks, $1275/mo.+sec+utilities. 815-575-6919
RENT TO BUY. Choose from 400 listed homes. Flexible Credit Rules. Gary Swift. Prudential First Realty.
815-814-6004
Crystal Lake: 4BR, 2BA
HARVARD 3 BEDROOM
CRYSTAL LAKE 3 BEDROOM NEWLY PAINTED. 3 BR, 2 1/2 BA. Attached 2 car garage. Quiet family neighborhood. Mins from Pingree Sta. $1425/month. 815-404-9076
McHenry. 3BR, 1BA. New carpet, paint. Stove, fridge. Large yard. Quiet area. Orchard Heights. $895. Pets ok. 847-217-3722
Large yard, $950/mo + util & sec. Call Larry Prudential First R. E. 815-353-8043
Harvard Country Living 2BR Farmhouse – Secluded. $980/mo + utilities & security, available now. 773-206-6221 Harvard: country home, 4BR, 2BA, appl., A/C, gar., $975/mo.+utils. & sec., 815-943-2235 Marengo 2 & 3BR, 2.5 BA, 2 car gar., $975-$1075/mo. Broker Owned 815-347-1712
MARENGO RURAL SETTING 1 acre, 3BR, 1.5BA, dinette. Large 2 car garage, pet with dep. $1050/mo. 815-291-9456
McCullom Lake 2BR, 1BA
$795/mo + sewer,1st & sec dep. Managing Broker Owned. Call Shawn 224-577-5521
McHenry 1BR, w/1 car gar , deck, fireplace, $790/mo. Broker owned 815-347-1712
McHenry Patriot Estates & Prairie Lake Townhomes Ask About our 1BR Special 2BR Starting at $1250.00. .
2 Car Garage, Pet Friendly Free Health Club Membership.
815-363-5919 or 815-363-0322
MCHENRY SHORES
4BR, 1.5BA, Managing Broker Owned. $1200/mo + sec. Pets ok w/dep. Call Shawn 224-577-5521
Ringwood Cozy 2BR Cottage Knotty pine porch, W/D, $900/mo. Tenant pays util. 815-245-0814
Wonder Lake ~ East Side 2-3 bedroom, detached garage. Fenced in back yard, lake rights. All appliances, W/D, $980/mo. 815-344-1839
WONDER LAKE ~ EAST SIDE 3 bedroom, $1090/mo. 2 story, large deck, W/D hook-up, pets OK. 773-510-3643 ~ 773-510-3117 Wonder Lake. 3BR, 2BA. 2 car garage. Across from lake. $1300/mo+sec dep. 847-459-3239 Wonder Lake: nice 2BR w/3 car gar., & lndry $890/mo Broker Owned 815-347-1712
Wonder Lake~Lake Front House Beautifully Remodeled 2BR, 1BA Huge deck and pier, $1150 + utilities, no dogs. 815-814-3348 Woodstock 2 & 3BR, new paint, fenced yard, 2 car gar., $850-$975/mo. Broker Owned 815-347-1712
WOODSTOCK
4BR, 2BA, W/D, all appl, Htd garage, $1250/mo., agent owned. 815-334-0199
Woodstock ~ 3 Bedroom 2 bath ranch, full basement. 2 car garage. $1300/mo. Available Now. 815-790-2039
BREAKING NEWS available 24/7 at NWHerald.com
FREE Classified Ad! Sell any household item priced under $400.
Visit nwherald.com/PlaceAnAd
Lake In The Hills 1 & 2BR
or use this handy form.
W/D, 1 car garage, no pets. 847-224-3567
MARENGO 1 BEDROOM
Grey male cat lost near the wooded area in between Riley Rd. & Greenwood Rd. in Wonder Lake, Please call 815-575-5254 if seen
McHenry $199 Move-In Special Large 1BR, from $699. 2BR, 1.5BA from $799. Appl, carpet and laundry. 815-385-2181
Mortorcylce Battery Cover
McHenry -1 & 2BR some utilities included, balcony $750 & UP Broker Owned 815-347-1712
# GS450LSalmon red, lost Thurs, Oct 24, near Route 14 in Crystal Lake. 815-459-4586
Woodstock: 2, 3 & 4BR, main floor & lndry, $710 & up, Broker Owned 815-347-1712
McHenry. 2BR, 1.5BA. 2 car gar. Whispering Oaks. Appls, lawn care incl. No pets, smoking. $1135/mo +utils, sec dep. 815-790-5508
Spacious 2BR, 2BA, D/W. W/D, C/A. Approx 1000 sq ft. $875/mo & up. 847-875-7985
$525/mo incl water & garbage. 815-651-6445
Female, lost on Wed, Nov 6 by Target in McHenry. If found, please call 815-385-9692
Fenced yard, Prairie Grove schools, nr Fox River, new deck and garage. $1250/mo. 847-833-5104
Woodstock 2 Bedroom
Incl all utilities + cable. No pets, no smoking. Near Square & train. $700/mo. 815-353-0056
Marengo: Lg 2 bdrm unit avail Immed. $750. All appl W/D, Dishwasher & micro furnished. Cent Air. No pets/no smoking. Sec dep, lease req. Tenant pays electric, cable. 224-858-7377
3rd Shift MAINTENANCE MECHANIC
Woodstock 1BR $645, 2BR $745 All appliances, wall to wall carpet. A/C, balcony On site laundry. No pets. 847-382-2313 708-204-3823
HYGIENISTS FT & PT needed immediately in McHenry. Call Kerry at 815-344-2264 to set up a working interview today! Fax resume to 815-344-2271 or email kerry@bullvalleydentistry.com
815-759-1900 / mjones@mc.net
Autumnwood Apt.
471 W. Terra Cotta Crystal Lake, IL No phone calls please:
815-334-9380
HARVARD 3BR, 2BA DUPLEX
Marengo: 610 E. Grant Hwy. & 1060 Briden Dr., 1BR $600-$645 or 2BR $700-$780 Roberto 773-317-3364 Sandra 815-568-6672
ILLINOIS CONCEALED CARRY CLASSES
Affordable Apts. Garage Included
WOODSTOCK UPPER 1BR
Fair Oaks Healthcare Center
Find !t here! PlanitNorthwest.com
❍ ❍
1 Bath, Available Immediately! Call for Details. 815-790-0517 All appliances incl, close to schools and hospital. Available Dec 1st. Call for details. 815-790-0517
Crystal Lake Cute 3BR, 1BA
1 & 2 Bedroom Rents Starting $735
WOODSTOCK FALL SPECIAL 2BR APTS Starting @ $750
HARVARD 2 BEDROOM
2 bath, finished basement, large fenced yard, 1 car garage, no pets. $1400/mo. 815-236-7191
SILVERCREEK
Near Square, stove, refrig, A/C. Utilities incl, no pets, no smoking. $575/mo + sec. 815-338-1534
815-653-7095 ~ 815-341-7822
HANDYMAN
Antioch Long Term Lease. Large 3BR, 2BA tri-level. 2.5 car attchd garage, fenced yard, deck, shed. Hardwood floors and all kitchen/ laundry appls. $1395.00 mo. Land Management Properties 815-678-4771
Crystal Lake 3 Bedroom Ranch
WOODSTOCK
Woodstock 2nd Floor Studio
SALES & INSTALLATION Experienced nanny/caregiver is looking for a job within 25 miles of CL, grt ref. available upon request., 773-814-4209
WOODSTOCK Very Nice Quiet 2 Bedroom $675 incl heat, non smoking. 815-206-4573
Close to metra, water and gas incl. Laundry in basement, no pets. Call for details. 312-953-7987
CAREGIVERS
Perfect Shutters is hiring exp. Injection Molding Technician. Duties include: Startup, processing, trouble shooting, insert changes, color changes. 80-2000 Ton Machine Exp a plus. Duties include: Setup, Startup, die changes, color change & process control. SIGN ON BONUS! Send to:
FT/PT for Gen. Pract. Office in Marengo.
Great References. 224-858-4515
Positions Available
Profile Extrusion Technician
Medical Assistant / Biller
SALES - High traffic Chain of Lakes Boat dealer is expanding their Sales force. Love Boating? Turn your passion into a career! Send resume to: mark@skipperbuds.com
Sales Associates- FT/PT for Gun Range On Target Range in Crystal Lake is looking for articulate, energetic men and women sales associates. Duties vary but first and foremost, employees must provide top flight customer service to the shooting public and represent On Target with integrity and enthusiasm. A background in the firearms industry is a plus but not required. A friendly disposition, good observation skills, and the ability to put customers at ease are characteristics we value. Apply to: Judy@ontargetsite.com
Saturday, November 9, 2013 • Page E3
✁
Headline:___________________________________________
Description:_________________________________________ __________________________________________________ __________________________________________________ Asking Price (required):________________________________ Best Time To Call:____________________________________
Beany has been found. Thank you to everyone that helped us find him. We are so happy to have him back.
Phone:_____________________________________________
❤Ceremonies of the Heart❤ Rev Anne 847-431-4014 Weddings, Blessings, Memorials, Christenings
Responsibilities include troubleshooting equipment & process issues, machine repair, installation, modifications and electrical work.
MCHENRY - ROUTE 31
IRISH PRAIRIE APTS
1 & 2 Bedrooms W/D and Fitness Center 815/363-0322
Qualified candidates must demonstrate a working knowledge of PLC's, Drives and Control Systems.
NAME:_____________________________________________ ADDRESS:__________________________________________ CITY__________________________STATE_____ZIP________
We offer an excellent starting wage and benefit package.
DAYTIME PHONE:____________________________________
Interested candidates should apply directly on For other job openings apply at EOE Fax: 847-356-0290 AA/EEO
E-Mail:_____________________________________________ Woodstock Studio $585/mo+sec. Efficiency $550/mo + sec.1-BR $650/mo + sec, all 3 furn'd w/all utils incl. No Pets. 815-509-5876
ALGONQUIN - 2 BEDROOM
MCHENRY QUIET BUILDING
Upgrade Your Ad
MCHENRY ~ 2BR, 2BA
! Add Bold $5 ! Add A Photo $5 ! Add an Attention Getter $5 ! ! !
1BR/$700 & 2BR/$750. Heat, water incl. NO PETS. Security deposit req. 815-382-6418 Nice, quiet, newer bldg. Balcony, fresh paint, new carpet, A/C. No pets. $850/mo. 847-343-4774
Quiet & clean building w/ storage, laundry & parking. 1 mo free rent. $800/mo. 847-401-3242
Algonquin Large 2 Bedroom Newly renovated, fenced yard, pet OK. $900/mo + security. 708-819-8286~847-331-7596 Algonquin: 1st flr, 2BR, 2BA, some utilities incl., $930/mo., Broker Owned 815-347-1712 ANTIOCH 1-bedroom $685, 2-bedroom $785 FREE heat and water. Wood/tile floors. On site laundry. 847-833-5505
Crystal Lake 1BR $760 Quiet building, hardwood floors, heat and water incl. No pets. 815-455-6964
McHenry: 1BR, 1 car garage, $725/MONTH Century 21 Roberts & Andrews Dennis Drake 815-342-4100 JOBS ANNOUNCEMENTS STUFF VEHICLES REAL ESTATE SERVICES LEGALS Find it all right here in Northwest Classified
LINE AD DEADLINE: Tues-Fri: 3pm day prior, Sat: 2pm Fri, Sun-Mon: 5pm Fri OFFICE HOURS: Mon-Fri, 8am-5pm PHONE: 815-455-4800
Mail to: Free Ads P.O. Box 250 Crystal Lake, IL 60039-0250 ! Sell an item priced Email: classified@shawsuburban.com
over $400 - $26
Ad will run one week in the Northwest Herald and on nwherald.com. One item per ad. Offer excludes real estate, businesses & pets, other restrictions may apply. We reserve the right to decline or edit the ad.
CLASSIFIED
Page E4• Saturday, November 9, 2013 Cary ~ Cozy Furnished Room
Private bath, $575 utilities incl. Cable hook-up and pool, garage. Close to shops and metra, cat OK. No smoking. 847-829-4449 Cary. Female roommate. Near train, pool, forest preserve, includes professional cleaning in common areas. $110 per week, $220 deposit. Call 815-236-5090 HARVARD ~ ROOM TO RENT in Large Home, quiet/friendly. Close to Metra. $400/mo, utilities, cable/wifi & laundry incl. 815-916-9804 WONDER LAKE ~ EAST SIDE Furnished Room, House privileges. Utilities and cable incl, $460/mo. 815-349-5291
CRYSTAL LAKE Lovely 4 BD, 2BA, split-level w/deck, FR & nice neighborhd. New Furn, Refrig,. W/d, carpet. Great Buy! $153,500 815337-6935 or 815-546-1033. CRYSTAL LAKE, Nice remodeled 4BD tri-level, 2BA w/fenced yd, deck, lrge strge shed, close to shls, $1400/mo. 847-815-6023
Lakewood estate lot 1.7 acres, no restrictions, previously sold for $130,000 now only $38,500 Broker Owned 815-347-1712
Crystal Lake Barn Storage Great for Motorcycles, Boats, RV's & Motorhomes. 815-477-7175
Hampshire Heated Car Storage $70/mo. Also Cold Storage for boats, cars, RV's, etc. 847-683-1963
MARENGO INSIDE POLE BARN STORAGE
PUBLIC NOTICE
5 spaces available, 30'x50' each. Nice, secure location, $295/mo. 815-568-7128
NOTICE OF INTENT TO DISPOSE OF ABANDONED AND UNCLAIMED PROPERTY. 8405 S ROUTE 31 CORP DBA ROUTE 31 24 HOUR SELF STORAGE 8405 ROUTE 31, CARY, IL 60013 WILL BE SOLD ON NOVEMBER 24, 2013 AT 10:30 AM
Crystal Lake CHEAP & CLEAN Office Suite. 300 SF.
Incl. all utils + High Speed DSL. $295/mo. 815-790-0240
WOODSTOCK OPEN HOUSE Sun, Nov. 10th, 1 – 4pm
418 S Madison St Vintage home Circa 1902 on a quiet tree lined street w/modern amenities incl granite counters & Hardwd floors. 3BD, 2.1 BA. 14 rare stained, leaded & beveled glass windows. $289,000 Molly Miller Prudential First 815-354-1880
THE FOLLOWING PROPERTY: UNIT A111 PROPERTY OF JACQUELINE BUENO UNIT A115 PROPERTY OF FRED ROGERS UNIT A209 PROPERTY OF TOM JUREK UNIT A303 PROPERTY OF ALEX ODUFU UNIT B117 PROPERTY OF JUSTIN ZARR UNIT C104 PROPERTY OF STUART CRAIG UNIT C202 PROPERTY OF STEVE JORDAN UNIT C302 PROPERTY OF TARA ENGELBRECHT UNIT D210 PROPERTY OF MICHAEL KING UNIT D302 PROPERTY OF IAN JOHNSON (Published in the Northwest Herald November 9, 16, 2013. #A2179)
PUBLIC NOTICE STATE OF ILLINOIS IN THE CIRCUIT COURT OF THE TWENTY-SECOND JUDICIAL CIRCUIT McHENRY COUNTYIN PROBATE
Celebrate the Holiday's in your new home. 303 Burr Ave., McHenry. Listing Price, $124,900.
MAKE AN OFFER! Ronnie Hurc, Sky High R. E. 312-613-6476
In the Matter of the Estate of BARBARA WEAVER GERNER, Deceased
Case No. 13 PR 00252 CLAIM NOTICE Notice is given of the death of BARBARA WEAVER GERNER of CRYSTAL LAKE, ILLINOIS Letters of office were issued on: 9/9/2013 to Representative: BARBARA KELLEY, 6113 SANDS RD, CRYSTAL LAKE, IL 60014-6550 whose attorney is: CAMPION CURRAN LAMB & CUNABAUGH, 16 N. AYER STREET, HARVARD, IL 60033. and to his attorney within ten days after it has been filed. /s/ Katherine M. Keefe Clerk of the Circuit Court (Published in the Northwest Herald October 26, November 2, 9, 2013 #A2122)
PUBLIC NOTICE STATE OF ILLINOIS IN THE CIRCUIT COURT OF THE TWENTY-SECOND JUDICIAL CIRCUIT MCHENRY COUNTY-IN PROBATE In the Matter of the Estate of GERALD R NITZ Deceased Case No. 13PR000283 CLAIM NOTICE Notice is given of the death of: GERALD R NITZ of: WOODSTOCK, IL Letters of office were issued on: 10/16/2013 to: Representative: LAURA J HOWARD 7418 TIMBER TRAIL MCHENRY, IL 60050 whose attorney is: THOMS, JEANNINE A 101 N VIRGINIA STREET SUITE 108 CRYSTAL LAKE, IL 60014. /s/ Katherine M. Keefe Clerk of the Circuit Court (Published in the Northwest Herald November 2, 9, 16, 2013. #A2160)
PUBLIC NOTICE STATE OF ILLINOIS IN THE CIRCUIT COURT OF THE TWENTY-SECOND JUDICIAL CIRCUIT MCHENRY COUNTY-IN PROBATE In the Matter of the Estate of ALAN R SWANSON Deceased
Clerk of the Circuit Court (Published in the Northwest Herald November 2, 9, 16, 2013. #A2161)
Northwest Herald / NWHerald.com ilding 815-444-9437 – Direct 815-444-9435 – General 815-444-9436 – Fax (Published in the Northwest Herald November 9, 2013. #A2207)
pr yo ground on these companies. This newspaper cannot be held responsible for any negative consequences that occur as a result of you doing business with these advertisers.
2004 FORD EXPEDITION
PUBLIC NOTICE
Loaded, heated/cool leather seats. New brakes/tires, well maintained! $6,200 815-690-0248
PUBLIC NOTICE OF REQUEST FOR BIDS/PROPOSALS McHenry County will accept sealed bids for BID #13-98 PROVIDE HP STORAGE AREA NETWORK SHELVES & DRIVES due November 21, 2013, at 3:00 PM (CST), in the office of Donald A. Gray, CPPB, Director of Purchasing, McHenry County Administrative Building- Room 200, 2200 N. Seminary Ave. Woodstock, IL 60098. Prospective bidders may obtain bidding documentation at: or departments/purchasing/Pages/ index.aspx or by contacting the purchasing department at 815-334-4818. All contracts for the Construction of Public Works are subject to Illinois Prevailing Wage Act (820 ILCS 130/1-12). (Published in the Northwest Herald November 9, 2013 #A2206)
PUBLIC NOTICE ASSUMED NAME PUBLICATION NOTICE
1995 Chevrolet G30
Public Notice is hereby given that on OCTOBER 25, 2013, a certificate was filed in the Office of the County Clerk of McHenry County, Illinois, setting forth the names and post-office address of all of the persons owning, conducting and transacting the business known as
53K miles, new battery, extra tires. Roof rack, trailer hitch, $4000/obo. 815-385-5145
1964 ½ Ford Fairlane Sport Coupe ~ 39K miles, runs good,
WHISPER AND SHOUT BOOKS
71,171 miles, original owner. $4,250 847-609-7586
located at 174 PETERSON PKWAY CRYSTAL LAKE IL 60014 Dated OCTOBER 25, 2013
1 Ton Extended Van
but needs work, $4500. 847-639-4114
1996 Ford Crown Victoria LX - 37K Original Miles, Ex Condition (Garage Kept), Power door locks, windows & seats, Lumbar support, Hunter Green Color $5500. 847-514-3082
1996 OLDS CIERA
/s/ Katherine C. Schultz County Clerk
4 door, original owner, V6, auto. A/C, garage kept, excellent cond! $1,500 847-658-7722
(Published in the Northwest Herald November 2, 9, 16, 2013. #A2152)
Notice is given of the death of: ALAN R SWANSON of: WOODSTOCK, IL Letters of office were issued on: 10/18/2013 to: Representative: DEBBIE EHLENBURG 12012 PLEASANT VALLEY WOODSTOCK, IL 60098 whose attorney is: PIERCEY & ASSOCIATES LTD 1000 HART RD FL 300 BARRINGTON, IL 60010-2624.
Claims against the estate may be filed within six months from the
/s/ Katherine M. Keefe
PUBLIC NOTICE
PUBLIC NOTICE The Village of Oakwood Hills, Illinois, is soliciting a Request for Qualifications for providing services to complete the Village's Stormwater Bioinfiltration Basins DesignBuild Project located at Silver Lake in southeast McHenry County. The work will include: providing all the necessary design, permitting and construction of two (2) stormwater bioinfiltration basins. Copies of the Request for Qualifications for the Village of Oakwood Hills Stormwater Bioinfiltration Basins Design-Build Project will be available for pickup beginning Tuesday November 12, 2013 at the Village of Oakwood Hills office located at 3020 North Park Drive, Oakwood Hills, IL 60013. Please call first for office hours to pick up a packet or e-mail Ken Smith at Ksmith@oakwoodhills.org. A pre-proposal meeting will be held at 2:30 p.m., Friday, November 22nd , 2013 at the Village Hall. If the applicant has any questions please contact: Ken Smith, Building Director 815-444-9437 Direct
The Illinois Classified Advertising Network (ICAN) provides advertising of a national appeal. To advertise in this section, please call ICAN directly at 217-241-1700. We recommend discretion when responding. Please refer questions & comments directly to ICAN. local Attorney General's Consumer Fraud Line and/or the Better Business Bureau. They may have records or documented complaints that will serve to caution you about doing business with. Again, contact the local and/or national agency that may be able to provide you with some backnd th ie This
1998 Ford Crown Victoria 140K mi. Great condition! $2500 OBO 815-245-3926
2001 Chrysler Sebring Convertible ~ Silver, 101K mi. A/C, $2,950. 847-830-0002 2003 MERCURY SABLE excellent condition well maintained with 157,000 miles moon roof satelite radio, remote start system 815-575-0521 $2999.00 or best offer
2003 TOYOTA AVALON
Loaded, 113K miles, heated seats, leather. Well maintained, $7,900. 847-669-0659 2005 Volvo T5 V50 Wagon, All wheel drive. Luggage Rack, Heated seats, skylight, 71 K miles. Single owner. $9,200. 815-715-3855
2009 Chevy Malibu LTZ 5500 mi, loaded, black w/black. $16,000 815-477-4152 2009 Mercury Grand Marquis Ultimate Edition. Fully loaded. Garage kept. Excellent cond. Only 17K mi. $14,500 OBO. 847-426-8955
Great Cars Available All Under $2500 Midtown ~ 2016 S. Route 31 815-378-9309 1957 Chevy Bellaire, 2 door post Good project car, garage kept, $10,000 847-507-0462 Northwest Herald Classified It works.
1998 Ford Windstar 3.8l, towing, 4 buckets. $1800. 815-728-1901 2002 Mercury Mountaineer: 1 owner, 7 passenger 4x4, loaded, heated seats, well maintained, FREE 3 month warranty, $4900, 815-344-9440 2003 Ford Windstar LX, 1 owner, super low miles, 61K only, fully loaded, FREE 3 month warranty $4500 815-344-9440
2004 Mini Cooper Rims White Aluminum, 17” x 7” Sport Rim w/Run Flat Tires - $399 firm 815-382-4743 before 8pm
McHenryCountySports.com is McHenry County Sports
REQUEST FOR QUALIFICATIONS FOR VILLAGE OF OAKWOOD HILLS' STORMWATER BIOINFILTRATION BASINS DESIGN – BUILD PROJECT
1998 Ford Super Club Wagon – V10, 165,800mi. Anti-lock brakes, Heavy Duty towing package+trailer brakes. $3,800 OBO. 815-568-6482
1996 Buick LeSabre
Case No. 13PR000009 CLAIM NOTICE
1998 Dodge Durango. 4WD. Runs good. All power, A/C. 8 cyl. $1700 OBO 815-307-8107
Bucket Seats Custom (like Captains Chairs) $60 ea. 847-973-2314
Bumper Hitch
Good condition, clams onto steel bumper, $25. 815-459-4586 McNeil Floor Liners for 2010-2014 Chevrolet Equinox. Front and Rear with Cargo Liner. Black w an Extra set of Front Liners. $125. Perfect Condition. 815-675-9070
Tires (4) Firestone FR710 P215/55R17, 35,000 miles left on tread, no repairs. $120/all 847-395-8325
Tires (4) Michelin
Size P26565R17, $160/obo. 815-353-6249
Weather Tech Lazer Mfg Liners For a 2012 Nissan Sentra. Black front mat liners, $75. 262-496-2614 Winter Snow Tires Mounted on Alloy Wheels. 4 Goodyear Eagle Ultra Grip Tires Mounted on 6 Spoke Alloy Wheels off VW Passat. 205/55R16 $395. 815-675-9070
RECRUIT LOCAL! Target your recruitment message to McHenry County or reach our entire area. For more information, call 800-589-8237 or email: helpwanted@ shawsuburban.com
PRE-OWNED
LIBERTYVILLE CHEVROLET 1001 S Milwaukee Ave Libertyville, IL
847/362-1400
BIGGERS MAZDA
KNAUZ NORTH
1320 East Chicago Street The Mazda Machine on Rt. 19, Elgin, IL
2950 N. Skokie Hwy • North Chicago, IL
1460 S. Eastwood Dr. • Woodstock, IL
Barrington & Dundee Rds. Barrington, IL
800/407-0223
800/935-5913
847/628-6000
Golf Rd. (Rt. 58) • Hoffman Estates, IL
BUSS FORD
INFINITI OF HOFFMAN ESTATES
111 S. Rte 31 • McHenry, IL
815/385-2000
SPRING HILL FORD
1075 W. Golf Rd. Hoffman Estates, IL
888/280-6844finitihoffman.com
847/235-8300 800/935-5909
MERCEDES-BENZ OF ST. CHARLES 225 N. Randall Road • St. Charles, IL
MARTIN CHEVROLET
800 Dundee Ave. • East Dundee, IL
877/226-5099
888/600-8053
5220 W. Northwest Highway Crystal Lake, IL
407 Skokie Valley Hwy. • Lake Bluff, IL
847/604-5000
MOTOR WERKS INFINITI
BULL VALLEY FORD/ MERCURY
MOTOR WERKS SAAB 200 N. Cook Street • Barrington, IL
800/935-5393
815/459-4000
TOM PECK FORD
ANTIOCH CHRYSLER DODGE JEEP
KNAUZ CONTINENTAL AUTOS
Barrington & Dundee Rds. Barrington, IL
13900 Auto Mall Dr. • Huntley, IL
105 Rt. 173• Antioch, IL
409 Skokie Valley Hwy • Lake Bluff, IL
800/935-5913
RAY CHEVROLET
847/669-6060
800/628-6087
847/234-1700fivestar.com
815/459-7100 or 847/658-9050
866/561-8676
ZIMMERMAN FORD
2525 E. Main Street • St. Charles, IL
CRYSTAL LAKE CHRYSLER JEEP DODGE
847/395-3600
BULL VALLEY FORD/ MERCURY
AUTO GROUP GARY LANG SUBARU
1460 S. Eastwood Dr. • Woodstock, IL
Route 31, between Crystal Lake & McHenry
MOTOR WERKS BMW
MOTOR WERKS CERTIFIED OUTLET Late Model Luxury PreOwned Vehicles 1001 W. Higgins Rd. (Rt. 71) or 1000 W. Golf Rd. (Rt. 58) • Hoffman Estates, IL
800/935-5909
39 N. Rte. 12 • Fox Lake, IL
RAYMOND CHEVROLET
REICHERT CHEVROLET 815/338-2780
AUTO GROUP - GARY LANG BUICK 815/385-2100
REICHERT BUICK 2145 S. Eastwood Dr. • Woodstock, IL
815/338-2780
AUTO GROUP - GARY LANG CADILLAC Route 31, between Crystal Lake & McHenry
AUTO GROUP - GARY LANG GMC Route 31, between Crystal Lake & McHenry
815/385-2100
Barrington & Dundee Rds. Barrington, IL
800/935-5913
888/800-6100
O’HARE HONDA
River Rd & Oakton, • Des Plaines, IL
ELGIN HYUNDAI
Route 120 • McHenry, IL
881 E. Chicago St. • Elgin, IL
815/385-7220
847/888-8222
200 N. Cook St. • Barrington, IL
KNAUZ HYUNDAI
AUTO GROUP - GARY LANG CHEVROLET Route 31, between Crystal Lake & McHenry
815/385-2100
AL PIEMONTE CHEVROLET
105 Rt. 173 Antioch, IL
800/628-6087fivestar.com
CRYSTAL LAKE CHRYSLER JEEP DODGE 5404 S. Rt. 31 • Crystal Lake, IL
888/800-6100
770 Dundee Ave. (Rt. 25) • Dundee, IL
847/426-2000
SUNNYSIDE COMPANY CHRYSLER DODGE
815/385-2000
RAY SUZUKI 888/446-8743 847/587-3300
BILL JACOBS MINI
847/202-3900
1564 W. Ogden Ave. • Naperville, IL
RAYMOND KIA
775 Rockland Road Routes 41 & 176 in the Knauz Autopark • Lake Bluff, IL Experience the best…Since 1934
800/295-0166
KNAUZ MINI
ELGIN TOYOTA
224/603-8611
409A Skokie Valley Hwy • Lake Bluff, IL
1200 E. Chicago St. Elgin, IL
847/604-5050
847/741-2100
300 East Ogden Ave. • Hinsdale, IL
888/204-0042
PAULY TOYOTA AUTO GROUP GARY LANG MITSUBISHI Route 31, between Crystal Lake & McHenry
LAND ROVER LAKE BLUFF
815/385-2100
375 Skokie Valley Hwy • Lake Bluff, IL
847/604-8100
847/234-2800
LAND ROVER HOFFMAN ESTATES
1051 W. Higgins • Hoffman Estates, IL
O’HARE HYUNDAI
119 Route 173 • Antioch, IL
LIBERTYVILLE MITSUBISHI
1035 S. Rt. 31, One Mile South of Rt. 14 Crystal Lake, IL
815/459-7100 or 847/658-9050
ANDERSON VOLKSWAGEN 360 N. Rt. 31 • Crystal Lake, IL
1119 S. Milwaukee Ave.• Libertyville, IL
888/682-4485
847/816-6660
800/731-5760
BILL JACOBS VOLKSWAGEN
2211 Aurora Avenue • Naperville, IL
800/720-7036
River Rd & Oakton, • Des Plaines, IL
888/553-9036
MOTOR WERKS PORCHE
Route 120 • McHenry, IL
815/385-7220
111 S. Rte 31 • McHenry, IL
1400 E. Dundee Rd., Palatine, IL
BILL JACOBS LAND ROVER HINSDALE
SUNNYSIDE COMPANY CHRYSLER DODGE
ANTIOCH CHRYSLER DODGE JEEP
BUSS FORD LINCOLN MERCURY
847/683-2424
ARLINGTON KIA IN PALATINE
888/538-4492
206 S. State Street • Hampshire, IL
800/935-5923
815/385-2100
23 N. Route 12 • Fox Lake
815/385-2100
MOTOR WERKS CADILLAC
MOTOR WERKS HONDA
FENZEL MOTOR SALES
AUTO GROUP GARY LANG KIA
815/385-2100fivestar.com
5404 S. Rt. 31 • Crystal Lake, IL
800/407-0223
800/628-6087
CRYSTAL LAKE CHRYSLER JEEP DODGE
888/800-6100
1107 S Rt. 31 between Crystal Lake and McHenry
ANTIOCH CHRYSLER DODGE JEEP 105 Rt. 173 • Antioch, IL
5404 S. Rt. 31 • Crystal Lake, IL
118 Route 173 • Antioch, IL
2145 S. Eastwood Dr. • Woodstock, IL
Route 31, between Crystal Lake & McHenry
630/584-1800
PAULY SCION 1035 S. Rt. 31, One Mile South of Rt. 14 Crystal Lake, IL
ANDERSON MAZDA 360 N. Rt. 31 • Crystal Lake, IL
888/682-4485
Barrington & Dundee Rds., Barrington, IL
800/935-5913
BARRINGTON VOLVO 300 N. Hough (Rt. 59) • Barrington, IL
MOTOR WERKS CERTIFIED OUTLET Late Model Luxury Pre-Owned Vehicles
1001 W. Higgins Rd. (Rt. 71) or 1000 W. 1000 W. Golf Rd. (Rt. 58) Hoffman Estates, IL
800/935-5909
847/381-9400
CLASSIFIED
Northwest Herald / NWHerald.com
A-1 AUTO
Will BUY UR USED CAR, TRUCK, SUV,
MOST CASH WILL BEAT ANY QUOTE GIVEN!! $400 - $2000 “don't wait.... call 2day”!!
BOAT STORAGE Seasonal Storage Starts at $150. Winterizing and Shrink-Wrap Avail. Midtown Storage 815-363-9466 BOAT TRAILER 20 foot 1991 Escort Boat trailer. Galvanized steel Frame with Hitch, winch mount, Fenders, Tires and Wheels, with title. Good condition $375. 847-209-3473 after 4 p.m.
TRAILER HITCH
Reese, complete with anti sway bar. 800# hitch weight, 10,000# trailer weight. LIKE NEW! $300 815-356-1803
96 Polaris XCR 600 Triple - many extras on this great sled. $1,100 815-900-1183
!! !! !!! !! !!
1990 & Newer Will beat anyone's price by $300. Will pay extra for Honda, Toyota & Nissan
815-814-1964 or
815-814-1224 !! !! !!! !! !!
WANTED: OLD CARS & TRUCKS FOR
$CASH$
Roll top desk: dark wood 50” wide 847-854-7980
Clothes – 3X & 4X tops, sweaters, pants, jackets - 2X dresses, nice clothes, some Walt Disney hoodies, Very Cheap - $.50 to $1.50 815-337-0749
COAT ~ LEATHER
Call us today: 815-338-2800 ROUTE 14 AUTO PARTS CAN'T GET ENOUGH BEARS NEWS? Get Bears news on Twitter by following @bears_insider
FREEZER/CHEST
J. C. Penney, white, 16.5 cu ft. Works great, $25.00. 847-658-8856 MICROWAGE, GE - JEM25, white, 1.0 cu ft, 800 watts, under cabinet or on counter, hardly used, $75, Crystal Lake, 815-236-4434 Microwave. Magic Chef. SS & black 1000W, 10 pwr levels, timer. $25. 815-861-3270
STOVE ~ GAS
Newer Amana White Self Cleaning Free Standing Stove Big Oven 5.1. Gently used by senior citizen. Nice condition, $275/obo. 815-308-5626
Washer and Dryer
Maytag, both work fine! $150/both. 815-337-5990
ANTIQUE CRAFTSMAN TABLE SAW All Steel – 10” Blade. Model 113.27520, Deck 27x30 with 10x27 Extensions. 3/4 HP Fence & Attachments. $150. Best time to call: ANY. 847-343-2025. ANTIQUE HOOVER VACUUM 1920 Model 105 Hoover Suction Sweeper. Looks & works great. McHenry IL. $65. Call or leave message: 815-385-1969.
Full length, only wore 3 times. Excellent condition! $25 815-385-7440
Antique Wood & Brass Carpenters or Tailors Square by R.H. Rosenberg, 12” x 24” $85 OBO. 847-426-9303
FASHION JEWELRY:
Avon Christmas Plates
8-10 Necklaces, 4 Rings 2 Arm Cuffs
EASILY WORTH $100 Cleaning out jewelry collection Getting rid of things I don't wear Photos on nwherald.com $20/FIRM will NOT separate 815-690-0527 lv mssg/text Fur Coat - Beaver Coat (Ladies) Size Med. 44" long. Cleaned & Stored $125.00. Call anytime. 815-455-4140. JACKETS - Summer jacket - white w/blue, yellow & pink, Size 3X, Nice - $10; Winter Ski Jacket – Zero Exposure, worn once or twice, light blue w/hood, size 4X - $30; Winter jacket – pretty new, cream, hood, size 3X, very nice - $15 815-337-0749 Leatther Jacket – Black, Size XL w/Hat “Crocodile Dundee” Worn 3 times, Very Nice $20. 815-337-0749
Snowmobile Suit
We pay and can Tow it away!
Reconditioned Appliances Lakemoor 815-385-1872
Dickens Heritage Village Collection People & Accessories. $300 OBO. 815-385-4353 Football Cards. Stars & Lots of Rookies. Price range $1-$40. Call: 815-338-4829 A great holiday gift!
Ladies, size 10/12, $50. 815-385-3269 Sterling silver necklace w/big medallion, new, never used $100 815-385-3269 TRENCH COAT w/zip out lining, beautiful regal royal blue, Size 3/4, like new condition, $45. Call 815 477-9023
BREAKING NEWS available 24/7 at NWHerald.com
from 70's & 80's. $150 OBO. 815-385-4353 Baseball Cards. Stars, Sets,Rookies. Price range $1-$40. Call: 815-338-4829 A great holiday gift!
Jacket ~ TCB Fan Club Orig. White Satin, Size Large, Never Worn Perfect for Xmas Gift $350. 630-723-1245
BARN SIDING
Collectibles: 3 Xavier Roberts, 23” Furskin Bears – Farrell, Hattie the Piemaker & the Beekeeper. Excellent Condition - $15 each 815-334-1078 Console Radio, 1950's era. Recordio by Wilcox-Gay. Blonde cabinet, good condition. Original phonograph, which also made recordings was replaced with a phonograph that only plays records. $50.00 815-385-0997 Cordial Glasses 14, Crystal. 7 3/4" tall - $180 815-363-8974 leave msg.
Dept 56 North Pole Series
Various pieces, as low as $10. 815-508-1114
Not mushroom. $35. 815-459-4586
Old Trunk – Embossed on outside w/mural on inside - $50 815-338-4428
Wood, Old and Antique. From Farm Building - $100. 815-943-6937 Door. NEW! Walnut Panel. 9'4”x42”x2” $175 815-354-5442 DOORS - 17 interior slab doors, all 2'-0 wide or smaller. Good for closets or may be used in pairs. These are old doors, but have never been installed. Asking $35 for the lot. 815-385-0997 DOORS - 2 exterior prehung doors. Steel clad, 2'-6x6'-8, left hinged. Used, but still in good condition, no dents but need paint. $50 for the pair or $30 each. 815-385-0997
PRECIOUS MOMENTS
Insulating Blankets
6 Piece Thanksgiving Dinner. $150. 815-382-2455
Many, for covering concrete, 6'x25' $20/ea. 847-514-4989
Precious Moments Christmas Wreath, $100. 815-382-2455
New & Used Lumber-Plywood $50. 815-943-6937
Stoneware Crock ~ 4 Crown 15 gallon, spotless, $30/obo. 815-276-2335
Sugar & Creamer Pickard Salt & Pepper, gold floral, $135. 815-459-3822
Tablecloth ~ Irish Linen Eyelet
and 10 Napkins, white, 110Lx80W, $80. 815-459-3822 VINTAGE INDUSTRIAL TYPE 3-HOLE PUNCH - Made by Master Products Mfg. Co. Model 3-25 black heavy duty, adjustable with lever action, works well. Made in the USA. $35. 815 477-9023
WARDROBE
From 1940's with glass doors. $150 815-209-5665
WARDROBE STEAM TRUNK From 1930's, $50. 815-209-5665
Basketball Cards Stars, Sets, Lots of Rookies. Price range $1-$50. Call: 815-338-4829 A great holiday gift!
Child's Dresser – Hand painted, 50 yrs old, 5 drawers & space on one side to hang outfits – Adorable! $150 815-338-4428 8am-4:30pm
Bike - Children's Trainer
Go-Glider, blue, 16”, orig. $120 like new! $60. 847-476-6771
Attic Fan With Thermostat
Misc. Vintage Kodak Cameras & Equipment. $35 OBO. 815-861-3270 Non-Sports Cards. '94 Marvel Masterpiece & Lots of Others. Sets at $25. Call: 815-338-4829 Great holiday gift!
Baby Clothing- Misc. girls Newborn to 9 months – Various Prices, Up to $4. 262-275-8085
Bird Cage - Victorian style. 30”square x 19” h with top peak at 7” h. 2 entrance ways in front. $65. 847-515-8012
20” Folding Bike - Not Used, Was $204.88, Asking $150. 847-521-2703
Hearse Model – Cadillac Includes Rolling Casket Holder $175. 815-569-2277
Ladder Back Chairs w/arms, (2). Rush Seat. Very old. Perfect Cond. $150 obo 815-861-1163
Whirlpool Cabrio: WED7300XWO 29'' Front-Load Eco Friendly Electric Dryer with 7.6 cu. ft. Capacity, 9 Drying Cycles, 5 Temp. Settings, Wrinkle Shield Option, AccuDry Sensor and LED Display, white. 10 mo's old. MSRP $899, Asking $375.00 815-455-3626
* 815-575-5153 *
I BUY CARS, TRUCKS, VANS & SUVs
WAHL APPLIANCE
Saturday, November 9, 2013 • Page E5
Breastpump - Medela brand Portable - Electric or Battery Excellent condition. $35. 262-275-8085 DRESS SET- Beautiful girls 2-Piece Dress & Coat set, size 4T. Longsleeve coat in black & white houndstooth design w/ Peter Pan collar, crystal buttons on the front. The short-sleeve dress features a black bodice over a houndstooth skirt with a white rose. Would be a pageant interview suit, Christmas attire. New with tags. $35. 815 477-9023 Fisher-Price "My Little Lamb Cradle "n Swing. $65 - Excellent condition 262-275-8085 Kelty Kids Backpack Carrier Blue - $65 815-900-1183 Pre-Fold Cloth Diapers. 24/15-30 lbs. 24/30-45 lbs. 10 diaper covers. Used 1 yr. $280 value. Asking $100. 847-476-6771
Pulldown Stairs ~ Wooden 10' drop, like new! $50 815-385-2829 Before 6pm
Sump Pump - Basement WatchDog Combo, 1/2 Hp Primary & Back Up Pump w/ Battery, Only Used 3 months, New $520, Asking $250. 815-814-5238 Trex Decking Wood 15 pieces, 1” x 5.5” x 20', Acorn brown, Perfect for small deck or porch project – Reg. $50 per board, Asking $200 for all 630-745-9607 UNDERGROUND METER SOCKET 100/200 amp. Perfect Condition. $50. Call anytime. 815 455-4140 Wood Paneling, 1x4-1x10 boards, random widths. All pieces 92" long. V-groove pecky cyprus. Used, stained one side, unfinished other side. Have 45 pieces, asking $45. 815-385-0997
CAKE PLATE & COVER - Vintage Retro Polished Chrome Square Cake Carrier with locking lid, fantastic condition for its age. Top locks onto serving tray with two push tabs. $35. 815 477-9023 LASER ETCHED IMAGE - Pieta, etched on 12” granite tile, image of Blessed Virgin Mary holding her beloved Son Jesus. Unique gift, comforting and reverent. Exceptional quality, NEW. $60. 815 477-9023.
Porcelain Bisque Dolls
Kept in display cabinet. Numbered, w/Certificates. Great as a Christmas gift? To start a collection for your child? $50/ea847-854-9878 Two Collectible Southern Lithographs by Artist Madeline Carol. A Magical Moment & Sharing Memories. Matching frames with glass. Signed with Certificates. $70 for both. Call 815-354-7718. Find. Buy. Sell. All in one place... HERE! Everyday in Northwest Classified
$500. Excellent cond. A Must See! Refurbished ones are listed for $999 online. 847-854-9878
4 year old male Long Coat Chihuahua He was relinquished with his best friend Libby when his guardian died. He is such a cuddler and lover. He also enjoys taking walks with his BFF.
LIBBY
3 year old female ShihTzu This adorable girl just got groomed so she is even cuter. Lovie and Libby are very bonded so we are hoping they can be adopted together.
J'ZARGO
1 year old female Tabby and White DSH She was relinquished when her guardian had to move. She was pregnant and gave birth to 5 kittens. Petite, sweet and ready to love you.
PRINTERS: Epson LQ1050
HP Color Paint Jet, Epson Stylus Color, IBM LaserJet "E", Canon S300 Color. All printers in excellent condition, $35/all. 847-854-9878 TV - 32” Emerson flat screen TV $150. 224-587-7522 or email: buyclassified@yahoo.com to arrange pickup.
TURTLE
Male - DSH Looking for a forever home. Turtle can be seen at the Crystal Lake Petsmart during business hours. He is shy at first and that is why he is named Turtle. Loves to carry around his toys.
BO & RHETT
815-455-9411
3Year Old Female Shepherd Mix I am smart and know lots of commands. I love to please you! I would love to be your one and only!
ICEE
5 year old Male White DSH I am a total riot! I even crack myself up! Want hours of entertainment, love , affection and fun! I am your man!
TV ~ SAMSUNG
TREADMILL Bionix Treadmill, good condition, asking $60. 815-276-7709
GINGER
815-459-6222 • mcac.petfinder.com Available NOW! We recently took in 3 litters of kittens of all ages! If you are looking for a kitten, we have one or maybe 2, for you!
SAGE
8 month old purebred Husky Gorgeous girl looking for a home with a fenced yard. Great with kids and other dogs. Pictures do not do her justice!
A Heart For Animals LAB PUPS
We have four 8 week old male yellow lab mix puppies in need of forever homes! they are as cute as can be!
ALICE
Five year old gorgeous Himalayan who would love to be the one and only pet
Resale Furniture & Tailor
MIXED FIREWOOD 310 Count Oak - Maple - Cherry, $85/FC. Free stacking and delivery. 815-334-7914
3314 W Pearl St. McHenry, IL 60050
(815) 404.0486 * * * ** * * * * * * *
2 Drawer Chest – Oak, Antique, Good Condition - $125 815-337-0749
Consignment Shop: Accepting Victorian & Edwardian Style Furniture on a 50%/50% Basis.
Bar Stools (4) Rattan w/tan seats $200/all 815-385-4353 BEDROOM SET - Dresser with mirror and shelves, chest and night stand, medium oak color. Asking $200. 815-276-4186 Beds w/Headboards – 2 Twin Size, Can be attached to make King Size Bed - $25 815-323-0091
Chairs - Dining Room chairs perfect cond. Windsor solid oak, 2 side $50/ea. 815-861-1163 Coffee/End Table. Hexagon. 2.5' across the flats. Enlosed w/doors for storage. $40 OBO. 847-515-3502 Couch – 6' Contemporary, light brown & cream, very good condition - $50. 815-338-9036 Curved glass, 48”x80”, $400/obo. Can email pics. 224-569-6348 Wood, 20x66x29H, 36x72x29H. $60. 847-476-6771 Having a Birthday, Anniversary, Graduation or Event Coming Up? Share It With Everyone by Placing a HAPPY AD!
Northwest Herald Classified 800-589-8237
SWIVEL ROCKERS (2) – Matching Patterned fabric. Excellent Condition. $125 OBO for the pair. Sold as set. 847-659-1852
Entertainment Center/Armoire Solid Oak, Beautiful, Very good condition, 56x20x58, holds up to 30 in wide TV. Picture available. Asking $400. 815-276-4186 Espresso Finish Pine Toddler Sleigh Bed, Dresser, Changing Table, Convertible Crib and 2 Mattresses : Gently Used, a few teething marks $250 for all 5 or $50 each piece. 815-479-0329
Headboard/Footboard
CURIO CABINET ~ OAK Desk Set - 2 Piece
SOFA great condition, green/gold pattern, reduced to $300; THREE TABLES, light wood tone $35 each; photo on request. 224-616-1371
Entertainment Center Solid Oak, 3 pieces, lighted w/smoke glass doors, 2 units; 22"W x 72"H, Middle unit; 36"W X 72"H, 32" Phillips TV included - Excellent Condition $140. 815 943-2331
BENCH
Zebra, 60” black and white, like new! $140. 815-404-8173
SOFA / TABLES
Entertainment Center & TV, 39”w x 43”h. Photo available $50. 815-276-7709
King size, hand carved, solid oak. $150 815-322-3948 HUTCH - Vintage Shabby Chic, cute lavender cottage hutch, shelves on top with cabinet at the base. Original hardware, clean & fresh. 67 H x 31 W x18 D. $295. 815 477-9023. KIDS TABLE AND CHAIRS - Super cute vacation seaside blue table and matching chairs for kids activities, play or learning, excellent condition, 28"L x 22"W x 19.5”H. $75. 815 477-9023
TABLE & CHAIRS - Great for country cottage kitchen appeal. Perfect for that first apartment, college dorm or your cute vintage space! $195. 815 477-9023. TABLE & CHAIRS -- 48 inch round solid oak pedestal table with 18 inch leaf. 6 chairs on castors. 815-307-8317 Table Set: 50” round, wooden, dining room table, platform height, w/4 chairs, table has storage, $125 815-404-8173 Table: 36” glass & chrome, bar height table, w/2 red leather chairs, great condition, $125 815-404-8173 Trunks. Rattan. Can be used for coffee and end tables. 1 w/glass top. $75/all. 815-385-4353
TWIN BEDS (2) With mattress and a dresser. Used but clean + some bedding. $100/obo. 847-587-1923
Kitchen Nook with One Table And 3 Benches, $100. 815-568-7133
Wall Unit w/46” Hitachi Large Screen TV, Completed Professional grade, Like New Wall Unit! Excellent Shape -$395 Call 857 854 8900
Wing Back Chair – Dark Red, Reclining. In Great Shape - $30 815-236-9536 after 5pm
YOUR NATURAL SOURCE FOR PET FOOD & MORE! )>>+ @9!LGB#< 2#.4 CAKL 5 % H$#KA" ,#?I94 D= 8++3*
Proud Sponsor of Pet of the Week Check us out on NWHerald.com!! '1F& 3*;086;0)++3 @@@.7:ECJ/H-//2.7/E
Males - Chihuahua - 1 year old Up to date on shots -They are super in the car, love to go for walks. Call Peg to meet them at 815355-9589 or see our facebook page for more pictures.
HEANEY'S R.V. INSIDE STORAGE "Lock-me-up"
Lock-ups Outside 815-403-6700 LOW RATES
12 year old Girl Orange Tabby I am a little nervous with all these cats and activity. I am treated wonderfully but I would love a quiet home of my own.
FREDDY
OREO
RUSTY
847-868-2432 One year old lab mix boy.Very sweet and smart. He gets along great with everyone.
On Angels’ Wings Pet Rescue Crystal Lake • 224-688-9739
Harrier Mix – Adult I am one of 44 dogs & puppies transported to be saved by Pets in Need fromTennessee.We were all scheduled to be euthanized because of overcrowding .We all are looking for our new start in life & a loving home.
MISSY MAE
American Bulldog – Young Adult Come meet Missy Mae and some of her friends at the Petco in McHenry from 11:00 a.m. to 3:00 p.m.
6 month old orange Tabby Fully vetted, very sweet, social, laid back big boy. Can be adopted any day of the week
MORDECAI
6 month old short hair all gray male kitten Fully vetted, playful and social. Good with other animals. See at the McHenry Petsmart
ALBERT
9 month old short hair buff and white boy Fully vetted, talkative, sweet. Good with other cats, very playful. See Albert at the Algonquin Petsmart.
Animal Outreach Society
815-385-0005 TEACHER
LOUISE
815-728-1462
M,T,Th,F 10:30-4:30; W 10:30-6:30; Sat 10-2:30
1 yr old Lab mix girl Oreo is a sweet girl that loves to sneak and give kisses when you least expect it. She is quiet but yet also very playful. Gets along with kids and other dogs.
Chihuahua Mix Senior Freddy is an owner relinquish. He likes to take walks and can be very sweet. He is looking to find his new loving home!
Anything on Wheels Inside Richmond, IL 847-587-9100
P.O. Box 58 • Ringwood, IL 60072 e-mail: pincare@earthlink.net
McHenry County Department of Health Animal Control Division 100 N. Virginia St. • Crystal Lake, IL 60014 Adoption Hours:
KITTENS
Dresser
White, Shabby Chic, $25. 815-455-2689 DVD CABINET – Solid Oak DVD Cabinet – 24”w x 36”h x 6”d. Excellent Condition. 4 shelves, can fit over 200 DVDs. $60. 847-659-1852
19” LED, like new! $100 847-658-4913
We are at the Crystal Lake Petsmart every Saturday from 11:00am to 1pm. • Email: info@assisi.org
MAGGIE
Dining Room Table & 2 Chairs Wood, 42” Round, 2 Leafs, 2 Side Chairs – Good Condition $75. 815-338-9036
TV by Panasonic Omnivision w/VHS, Includes Video In, Audio in & front hookups, white, 14” Great for kids - $35 OBO 815-337-2911 Woodstock
RECLINER ~ LA-Z-BOY
Dark green, $75. Stripe arm chair, like new! $75. (2) glass table lamps, $30both. Small end table with drawer at bottom, $20. Wall picture, snow scene, size 32Hx45W with gold frame, cost $250, sell for $50. 847-845-3702 ROCKING CHAIR Solid maple. $60 815-385-4353 Roll Top Desk and Chair Dark walnut. $100 815-385-4353 Round Table – Older, Solid Oak Unique Size, Great for game table, TV or displays, 42” diameter, 26” high - $160 OBO - Woodstock 815-337-2911 RUSTIC FULL SIZE BED HEADBOARD. We have about a dozen, in good condition, $60 each, Harvard, IL. Some people buy 2, saw off bottom of 1, and create a footboard out of one of them, making a gorgeous bed! They have holes, which are not visible when bed is installed, where screws were put in before. You will need to drill small holes to install a bedframe, which is not included. Text or call Katy at 815-409-9261 Side table w/big drawer, Colonial style - $25 815-337-0749
7:ECJ/(H -//2
815-338-4400
CASEY
DINING ROOM SET TABLE seats 6-12; 6 cane back upholstered chairs; China has beveled glass; light finish wood; excellent condition. Reduced to $700. 224-616-1371
Plush Chair – Extra Large, Feather Down, Gold Color – Good For Bad Backs – Nice Condition - $80 815-337-0749 Robin
Located next to the Spring Grove Post Office.
Helping Paws Animal Shelter 2500 HARDING LANE, WOODSTOCK, 60098
Male - Pekinese Mix - 5 years old Found as a stray in Aurora. This little guy is super fun to be with. He loves to go for walks and play. He is up to date on all shots, micro chipped and neutered.
MIRROR
Gold framed, 42x30, excellent condition, $20. 847-515-3986
Printer. Epson. High Definition. Color. New, in box. $40 815-455-6627
• Natural Pet Foods & Supplies • In Home Pet Sitting • Dog Training • Doggy Daycare • Overnight Boarding LOVIE
Lazy Boy Recliner Chair – All Leather, Gray Cover, Excellent Condition, No Marks or Wear $125 OBO. 224-489-4829
HP DesignJet 650C Plotter
BAMBI
Tiger and White Female Kitten Bambi is a loving 16 week old who was bottle fed after being orphaned at a young age.
DARRIN
Orange and White Male Kitten Darrin and his 4 siblings are sweet, playful 5 month old kitties. $75 adoption donation for kittens.
A.S.A.P., Marengo 815-568-2921
See our cats daily at the Petsmarts in McHenry and Algonquin
LIBBY
Black/White Tuxedo Female Adult Libby is a total lap cat who loves to cuddle. She raised 8 kittens and now it is her turn to be pampered. Meet her, Darrin, and Bambi today at Farm & Fleet!
Stop by Farm & Fleet in Woodstock today from 10:30-2 to meet these kitties and many others
Advertise your business here for $25.00 per week or $80.00 w/4 week run. Call Asma at 815-526-4459
CLASSIFIED
Page E6• Saturday, November 9, 2013
Northwest Herald / NWHerald.com
AT YOUR SERVICE
In print daily Online 24/7
Visit the Local Business Directory online at NWHerald.com/localbusiness. Call to advertise 815-455-4800
JR CUSTOM PAINTING
D. K. QUALITY TUCKPOINTING & MASONRY ✦ Tuckpointing ✦ Chimney Repair/Caps ✦ Brick & Stone
JUNK REMOVAL SERVICES
Digital Landscape Design & Installation Hardscapes & Pavers Patios, Sidewalks & Driveways Lawn Care & Maint. Annual Lawn Care Service Contracts Tree/Shrub Trimming & Pruning Spring & Fall Clean-Ups Snowplowing REASONABLE PRICES FREE ESTIMATES FULLY INSURED
Holiday Special
(815) 482-6072 (815) 482-5408
Free Pick-Up
Fully Insured Free Estimates
High Quality Residential Painting Service Interior/Exterior Power Washing ✦ Wall Paper Removal FREE ESTIMATES FULLY INSURED Senior & Veteran Discount ✦ ✦
Joe Rau, Owner 815-307-2744
Appliances, Electronics Any Kind of Metal or Batteries
Owner Is Always On Job Site!
815-482-8406
847-525-9920
POWER Tree & Stump Removal, Inc. ✲ ✲ ✲ ✲
815-943-6960 24 Hour Emergency Cell 815-236-5944
✲ ✲ ✲ ✲
M.E.N.D SERVICES FOR ALL YOUR GUTTER NEEDS!
Eddie's Tree Service SEASONED FIREWOOD
*GUTTER CLEANING *SCREENING *REPAIRS & INSTALLATIONS
Serving All of Northern Illinois Fully Insured Over 20 Years of Experience & Service
847-951-2632 Visa & Mastercard Accepted
Face Cord of Mixed - $90 Imperial Drywall & Remodeling ✦ ✦ ✦ ✦ ✦
Home Repair Hang, Tape & Repair Framing & Insulation Basement Finishing Our Specialty: Electrical & Plumbing Repairs
FREE ESTIMATES Insured, Quality Work Reasonable Rates
815-735-0779 All NIU Sports... All The Time
Also Available Oak Cherry Hickory Birch
FULLY INSURED
JULIO'S LANDSCAPING
Outsiders Landscaping
Complete Customized Designs/Maintenance ! ! ! ! ! ! ! ! FALL CLEAN-UP ! ! SNOW PLOWING ! ! ! ! ! ! ! ! Commercial/Residential
Commercial and Residential
Snow Removal
* Trimming & Removal * Specializing Large & Dangerous Trees * Storm Damage * Lot Clearing * Stump Grinding * Pruning McHenryCountySports.com is McHenry County Sports
We are At Your Service!
Fall Cleanups Also Available
FREE ESTIMATES LOW PRICES FULLY INSURED
Serving McHenry & Surrounding Counties
815-477-1322 815-219-8088 JOBS, JOBS and MORE JOBS! No Resume? No Problem!
CALL FOR A FREE
Monster Match assigns a professional to hand-match each job seeker with each employer!
773-569-1681
ESTIMATE!
This is a FREE service! Simply create your profile by phone or online and, for the next 90-days, our professionals will match your profile to employers who are hiring right now!
Pick Up or Delivered
CREATE YOUR PROFILE NOW BY PHONE OR WEB FREE!
4617 S. Route 47 Woodstock, Il
Having a Birthday, Anniversary, Graduation or Event Coming Up?
1-800-272-1936
815-337-1799 847-875-4077
or Being the FIRST to grab reader's attention makes your item sell faster!
DON'T NEED IT? SELL IT FAST!
Highlight and border your ad!
Northwest Classified Call 800-589-8237
800-589-8237
Sometimes you just can’t do it yourself ... ...and getting upset isn’t worth it!
NWHerald.com/jobs No Resume Needed! Call the automated phone profiling system or use our convenient online form today so our professionals can get started matching you with employers that are hiring - NOW!
RECRUIT LOCAL! Target your recruitment message to McHenry County or reach our entire area. For more information, call 800-589-8237 or email: helpwanted@ shawsuburban.com
Share It With Everyone by Placing a HAPPY AD!
Resale Furniture & Tailor
3314 W Pearl St. McHenry, IL 60050
(815) 404.0486 * * * ** * * * * * * *
The Northwest Herald reaches 137,000 adult readers in print every week, and 259,000 unique visitors on NWHerald.com every month.
Call to advertise in the At Your Service directory. In the Northwest Herald classified everyday and on PlanitNorthwest Local Business Directory 24 hours a day, 7 days a week.
planitnorthwest.com/business Northwest Herald Classified 800-589-8237
Jeans Hemmed: $6/ea
800-589-8237 classified@shawsuburban.com
The AT-YOUR-SERVICE Directory is the answer to your problem! To Place Your Service Directory Ad Call
815.455.4800 815.526.4645
CLASSIFIED
Northwest Herald / NWHerald.com
! !
! !
! !
SUDOKU
Saturday, November 9, 2013 • Page E7
CROSSWORD
HOROSCOPE
! !
TODAY - Choose events that broaden your outlook or have the potential to bring you in contact with creative people. Inspiration will help you use your assets and qualities more effectively. A close relationship will improve your life.term plans and consider your options regarding work and money. Putting a budget in place by cutting your overhead will help ease stress.
JUMBLE
SATURDAY EVENING NOVEMBER 9, 2013 5:00
5:30
6:00
6:30
7:00
7:30
8:00
8:30
9:00
9:30
10:00
10:30
11:00
11:30
12:00
12:30
CBS 2 News at (:35) Criminal Minds The team tries (:35) CSI: Miami “Payback” The (:35) White Col(2:30) College Football: Mississippi Entertainment Tonight (N) ’ (CC) College Football: LSU at Alabama. (N) (Live) (CC) ^ WBBM State at Texas A&M. (N) 10PM (N) (CC) to expose a mole. ’ (CC) CSIs probe the murder of a rapist. lar “All In” (12:03) 1st (:33) 24/7: NBC5 News 10P (:29) Saturday Night Live Host and musical guest NBC5 News 5P NBC Nightly Access Hollywood (N) ’ (CC) Ironside ’ (CC) Miss Universe Women vie for the crown. (N) ’ (CC) % WMAQ (N) (CC) Secrets of the News (N) (CC) (N) (CC) Look ’ Miley Cyrus. ’ (CC) Weekend ABC7 ABC World On the Red Private Practice Addison’s brother College Football: Teams TBA. (N) (Live) (CC) (2:30) College Football: Teams ABC7 News ’ (CC) _ WLS TBA. (N) (Live) Carpet News ’ (CC) News moves to Los Angeles. ’ (CC) Living Healthy Chicago’s Best Two and a Half Blackhawks NHL Hockey: Chicago Blackhawks at Dallas Stars. From American Airlines Center in Dallas. WGN News at 30 Rock “Tracy 30 Rock “The Movie: ››› “The Matrix” (1999, Science Fiction) Keanu Reeves. A ) WGN Chicago Extra (N) (CC) (N) ’ (Live) (CC) Nine (N) (CC) Does Conan” Break-Up” ’ “Best Italian” computer hacker learns his world is a computer simulation. (CC) Men ’ (CC) Rick Steves’ Moveable Feast PBS NewsHour McLaughlin Keeping Up Keeping Up Doc Martin Louisa’s mom arrives (8:50) Death in Paradise An old Jimi Hendrix: American Masters The life of guitarist Jimi Hendrix. (N) Masterpiece Classic Matthew and + WTTW Europe (CC) With Fine Appearances Appearances unexpectedly. ’ (CC) colleague of Richard’s turns up. William’s uncertain fates. (CC) Weekend (N) ’ Group (N) ’ (CC) Antiques Roadshow Eskimo hunt- A Blackfeet Encounter Lewis and Musicology: Live from Old Town DCI Banks “Playing With Fire” Evidence points to an Just Seen It ’ The Café “Reap Lead Balloon Independent Lens “Waste Land” Vik Muniz photoAutoline ’ (CC) 4 WYCC What You Sow” “Giraffe” (CC) graphs garbage-pickers. ’ (CC) (CC) ing helmet; silver spoon. ’ (CC) Clark clash with Indians. ’ (CC) School of Folk Music art forgery scam. ’ (CC) Pro Wrestling Whacked Out Cheaters Boyfriends with room- Video Spotlight Unsealed: Alien Are We There Futurama “Deci- Movie: ›› “Pirates of the Caribbean: At World’s End” (2007, Action) Johnny Depp, Orlando Bloom, Keira Ring of Honor Wrestling (CC) 8 WCGV Yet? Files (N) (CC) Report Sports ’ mate, co-worker. (N) ’ (CC) sion 3012” ’ Knightley. Jack Sparrow’s friends join forces to save him. American Dad American Dad Family Guy (CC) American Dad Futurama “Deci- Futurama ’ That ’70s Show That ’70s Show Seinfeld “The Family Guy (CC) Family Guy ’ Futurama ’ American Dad American Dad Cheaters Boyfriends with room: WCIU “Sally Simpson” “Killer Vacation” ’ (CC) “Haylias” (CC) sion 3012” ’ (CC) Hot Tub” (CC) (CC) (CC) ’ (CC) ’ (CC) “Surro-Gate” ’ mate, co-worker. (N) ’ (CC) Animation Domination High-Def Whacked Out Mancow Mash Paid Program Fox 32 News at Nine (N) College Football: Texas at West Virginia. (N) ’ (Live) (CC) @ WFLD College Football FOX College Ask This Old PBS NewsHour Antiques Roadshow Boston Celtics Movie: ›››› “East of Eden” (1955, Drama) James Dean, Julie Harris. Himalaya With Michael Palin Start Up ’ (CC) Scott & Bailey The team is called in We Served Too:The Story of the The Jack Benny D WMVT Women’s Airforce Service Pilots Show for a burned body. (CC) Gurkha recruitment; Annapurna. Rebel Cal and twin Aron vie for their rigid father’s love. House ’ (CC) Weekend (N) ’ memorabilia; ring; book. (N) ’ Monk Monk has insomnia. (CC) Monk ’ (CC) Monk ’ (CC) Monk ’ (CC) Monk ’ (CC) Monk ’ (CC) Monk Monk falls under a spell. ’ F WCPX Monk ’ (CC) News Animation Domination High-Def Bones “The Babe in the Bar” ’ Two/Half Men Big Bang College Football: Texas at West Virginia. (N) ’ (Live) (CC) G WQRF Sports Connect FOX College Bones Old classmates unearth a Inside the Bears Billy Graham: The Simpsons The Simpsons The Simpsons The Simpsons The Closer “Living Proof: Part One” The Closer Brenda’s parents’ RV is Crime Stoppers Hollyscoop (N) EP Daily (N) ’ EP Daily (N) ’ R WPWR Case Files Good News “Fear of Flying” ’ (CC) The squad’s holiday plans. robbed. (Part 2 of 2) (CC) (CC) (CC) time capsule. ’ (CC) ’ (CC) ’ (CC) ’ (CC) CABLE 5:00 5:30 6:00 6:30 7:00 7:30 8:00 8:30 9:00 9:30 10:00 10:30 11:00 11:30 12:00 12:30 (:01) Flipping Vegas “Cat House” Storage Wars Storage Wars Storage Wars Storage Wars (A&E) Storage Wars Storage Wars Storage Wars Storage Wars Storage Wars Storage Wars Storage Wars Storage Wars Flipping Vegas “Frat House” (N) Movie ›› “Jurassic Park III” (2001, Adventure) Sam Neill. A search Movie ››› “X-Men” (2000, Action) Hugh Jackman, Patrick Stewart, Ian McKellen. PreMovie › “Catwoman” (2004, Action) Halle Berry, Benjamin Bratt. A shy Movie ›› “Christine” (1983, Horror) Keith Gordon, (AMC) party encounters new breeds of prehistoric terror.‘PG-13’ miere. Two groups of mutated humans square off against each other.‘PG-13’ artist acquires feline strength and agility.‘PG-13’ (CC) John Stockwell, Alexandra Paul.‘R’ (CC) To Be Announced (ANPL) To Be Announced Too Cute! (N) ’ (CC) Pit Bulls and Parolees ’ (CC) Pit Bulls and Parolees ’ (CC) Pit Bulls and Parolees ’ (CC) Pit Bulls and Parolees ’ (CC) Too Cute! ’ Anthony Bourdain Parts Unknown Anthony Bourdain Parts Unknown Inside Man “Immigration” Anthony Bourdain Parts Unknown Anthony Bourdain Parts Unknown (CNN) CNN Newsroom (N) Movie: ››› “Pandora’s Promise” (2013, Documentary) (:31) Tosh.0 (12:01) Tosh.0 (:31) Tosh.0 (COM) (4:58) Futurama (:28) Futurama (5:59) Futurama (:29) Futurama Movie: › “Grandma’s Boy” (2006) Doris Roberts, Allen Covert. (CC) Movie: ››› “Scott Pilgrim vs. the World” (2010) Michael Cera. Premiere. (CC) College Football Hard Charge SportsNet Cent College Basketball: Drake at Illinois-Chicago. (N) (Live) Chicago Huddle Football Weekly SportsNet Cent SportsNet Cent Bensinger 3 and Out SportsNet Cent Basketball (CSN) (DISC) Moonshiners ’ (CC) Fast N’ Loud ’ (CC) Fast N’ Loud ’ (CC) Fast N’ Loud ’ (CC) Fast N’ Loud ’ (CC) Fast N’ Loud ’ (CC) Fast N’ Loud ’ (CC) Fast N’ Loud ’ (CC) Lab Rats “Paral- Kickin’ It ’ (CC) Jessie ’ (CC) Dog With a Blog Shake It Up! ’ Good Luck Dog With a Blog Liv & Maddie ’ Jessie ’ (CC) Jessie ’ (CC) Movie ›› “The Game Plan” (2007) Dwayne “The Rock” Johnson. A Jessie ’ (CC) A.N.T. Farm (DISN) Charlie (CC) “managemANT” (CC) (CC) lel Universe” ’ ’ (CC) ’ (CC) carefree football player learns he has a daughter. ’ ‘PG’ (CC) (3:05) Movie:“A (:25) Movie: ››› “Identity” (2003) John Cusack. A Movie: ››› “The Amazing Spider-Man” (2012, Action) Andrew Garfield, Emma Stone. (:20) Movie: ››› “Robocop” (1987, Science Fiction) (:05) Movie: ››› “The Fifth Element” (1997) Bruce Willis, Gary Old(ENC) Knight’s Tale” killer terrorizes people stranded at a remote hotel. Premiere. Peter Parker investigates his parents’ disappearance. ’ (CC) Peter Weller, Nancy Allen, Ronny Cox. ’ (CC) man. A New York cabby tries to save Earth in 2259. ’ (CC) College Football: UCLA at Arizona. (N) (Live) (CC) SportsCenter (N) (Live) (CC) (ESPN) College Football College Football College Football: Teams TBA. (N) (Live) (CC) (:15) College Football: Fresno State at Wyoming. (N) (Live) (CC) (12:15) College Football Final (N) (ESPN2) NASCAR Racing College Football College Football: Houston at Central Florida. (N) (Live) (CC) (FAM) (3:00) Burlesque Movie: ››› “Dirty Dancing” (1987, Romance) Jennifer Grey, Patrick Swayze. Movie: ››› “Grease” (1978, Musical) John Travolta, Olivia Newton-John. Movie: ›› “Grease 2” (1982, Musical Comedy) Maxwell Caulfield, Michelle Pfeiffer. Justice With Judge Jeanine FOX Report (N) Huckabee (N) Justice With Judge Jeanine (N) Geraldo at Large (N) ’ (CC) Red Eye (N) (FNC) America’s News Headquarters Geraldo at Large ’ (CC) Diners, Drive Diners, Drive Cupcake Wars “Barbie” (N) Food Network’s 20th Birthday All-Star Family Cook-off Restaurant Divided Food Network’s 20th Birthday All-Star Family Cook-off (FOOD) Restaurant Express Sons of Anarchy “John 8:32” (FX) Movie: ›› “Hancock” (2008, Action) Will Smith, Charlize Theron. Movie: ›› “Iron Man 2” (2010, Action) Robert Downey Jr., Gwyneth Paltrow. Movie: ››› “Spider-Man 2” (2004, Action) Tobey Maguire, Kirsten Dunst. Movie: ›› “A Princess for Christmas” (2011) Katie McGrath, Roger Movie:“Snow Bride” (2013, Drama) Katrina Law, Jordan Belfi, Susie Movie: ››› “Debbie Macomber’s Mrs. Miracle” (2009) James Van Der Movie:“Debbie Macomber’s Call Me Mrs. Miracle” (2010) Doris Rob(HALL) erts. A new employee saves a store in trouble at Christmas. (CC) Abromeit. Premiere. A tabloid reporter falls for a politician’s son. (CC) Beek. A single man hires a nanny for his 6-year-old twins. (CC) Moore. An English duke reconnects with members of his family. (CC) House Hunters Hunters Int’l House Hunters Hunters Int’l House Hunters Hunters Int’l House Hunters Hunters Int’l Love It or List It,Too (CC)) Ax Men “Fight to the Finish Line” Pawn Stars Movie:“A Country Christmas Story” (2013) Dolly Parton, Desiree Ross. Movie:“Christmas Angel” (2009) K.C. Clyde, Kari Hawker. A woman (:02) Movie:“A Country Christmas Story” (2013, Drama) Dolly Parton, Movie: ››› “The Christmas Blessing” (2005, Drama) Neil Patrick Har(LIFE) Premiere. A country-music singer reunites with her father. (CC) assists a man who helps others during the holidays. (CC) Desiree Ross. A country-music singer reunites with her father. (CC) ris. A medical resident falls in love with a young teacher. (CC) Caught on Camera Caught on Camera Lockup Lockup Lockup Lockup Lockup (MSNBC) Caught on Camera (MTV) Teen Mom 3 “Taking Chances” Scrubbing In ’ Movie: ›› “Step Up” (2006, Musical) Channing Tatum, Jenna Dewan, Mario. ’ Movie: ›› “Step Up 2 the Streets” (2008) Briana Evigan. ’ Movie: ›› “You Got Served” (2004, Drama) ’ Hathaways Thundermans Hathaways (NICK) Hathaways Sam & Cat ’ Sam & Cat ’ Sam & Cat ’ Hathaways Instant Mom ’ Full House ’ Friends (CC) (:33) Friends ’ Old Christine Old Christine George Lopez George Lopez (3:00) Movie: Cops “Family Cops “U.S. Mar- Cops “Taken Into Cops (N) ’ (CC) Cops ’ (CC) Cops “Stupid Cops “Neighbor- Movie: ››› “The Departed” (2006, Crime Drama) Leonardo DiCaprio, Matt Damon, Jack Nicholson. An undercover cop and a World’s Wildest (SPIKE) “Training Day” Police Videos Behavior No. 5” hood Busts” Ties No. 2” ’ shals” ’ (CC) Custody” criminal lead double lives. ’ (4:00) Movie:“Piranhaconda” Movie:“Lake Placid 3” (2010, Horror) Colin Ferguson, Yancy Butler, Movie:“Bering Sea Beast” (2013, Horror) Cassie Scerbo. Premiere. Movie:“Robocroc” (2013, Science Fiction) Corin Nemec, Steven Hartley. Movie:“Bering Sea Beast” (2013) (SYFY) (2012) Michael Madsen. (CC) Kacey Barnfield. Baby crocodiles become monstrous man-eaters. (CC) Siblings disturb a colony of vampires in an underwater cave. A crocodile transforms into a metallic, killing machine. (CC) Cassie Scerbo, Jonathan Lipnicki. Movie: ››› “Sergeant Rutledge” (1960, Western) Jeffrey Hunter. An Movie: ››› “Gold Diggers of 1933” (1933) Joan Blondell, Ruby Keeler. Movie: ›› “The Reformer and the Redhead” (1950) June Allyson. An Movie: ››› “Cornered” (1945, Suspense) Dick Powell, Walter Slezak. A (TCM) innocent black soldier is charged with rape and murder. (CC) Unemployed showgirls help a producer stage a show. (CC) attorney saves the day for a zookeeper’s daughter. (CC) vengeful Canadian airman seeks a Nazi war criminal. (CC) (TLC) Hoarding: Buried Alive ’ (CC) Hoarding: Buried Alive ’ (CC) Untold Stories of the E.R. (CC) Untold Stories of the E.R. (CC) Untold Stories of the E.R. (CC) Untold Stories of the E.R. (CC) Untold Stories of the E.R. (CC) Untold Stories of the E.R. (CC) (3:30) Invincible Movie: ›› “The LongestYard” (2005) Adam Sandler, Chris Rock. (CC) (DVS) (TNT) Movie: › “Rush Hour 3” (2007, Action) Jackie Chan. (CC) (DVS) Movie: ›› “Talladega Nights:The Ballad of Ricky Bobby” (2006) Movie: ››› “Total Recall” Andy Griffith Andy Griffith Andy Griffith Andy Griffith Andy Griffith Andy Griffith Love-Raymond Love-Raymond Love-Raymond Love-Raymond Love-Raymond Love-Raymond King of Queens (:38) The King of Queens (CC) King of Queens (TVL) NCIS “Toxic” A government scientist Modern Family Modern Family Modern Family Modern Family Modern Family Modern Family Modern Family Modern Family White Collar “At What Price” Neal (:01) Law & Order: Special Victims (12:01) Law & Order: Special (USA) “Career Day” tries to clear Peter’s name. (CC) Unit “Birthright” ’ (CC) Victims Unit “Debt” ’ (CC) goes missing. ’ (CC) “Schooled” ’ “Snip” (CC) ’ (CC) ’ (CC) ’ (CC) “My Hero” ’ ’ (CC) (VH1) Movie: ›› “Liar Liar” (1997) Jim Carrey, Maura Tierney. ’ Movie: ››› “8 Mile” (2002, Drama) Eminem, Kim Basinger, Brittany Murphy. ’ Behind the Music “Nas” Nas. ’ Behind the Music Ludacris. (CC) Love & Hip Hop “Stray Bullet” ’ Chrissy & Jones Big Bang Big Bang Big Bang Big Bang Big Bang Trust Me, I’m Movie: ›› “Just Friends” (2005) Ryan Reynolds, Amy Smart. Sweetest Thing (WTBS) Love-Raymond Love-Raymond Love-Raymond Love-Raymond Big Bang PREMIUM 5:00 5:30 6:00 6:30 7:00 7:30 8:00 8:30 9:00 9:30 10:00 10:30 11:00 11:30 12:00 12:30 Boxing: Mikey Garcia vs. Rocky Martinez. Garcia takes on Martinez in the 12-round main (:15) 24/7 Pac- (:45) 2 Days: Boardwalk Empire Nucky refuses Movie ›› “I, Robot” (2004, Science Fiction) Will Smith. A homicide Movie ›› “Taken 2” (2012, Action) Liam Neeson. A (HBO) quiao/Rios (N) Andre Ward ’ to back Chalky. ’ (CC) vengeful father abducts Bryan Mills and his wife. event. From Corpus Christi, Texas. (N) ’ (Live) (CC) detective tracks a dangerous robot in 2035. ’ ‘PG-13’ (CC) (:10) Strike Back: Origins Porter Movie ››› “Life of Pi” (2012) Suraj Sharma. A teenager and a tiger (:10) Strike Back: Origins Porter The Girl’s Guide Movie “Serena (4:15) Movie ›› “Warm Bodies” Movie ››› “Ocean’s Twelve” (2004) George Clooney. Indebted crimi(MAX) enters Zimbabwe in disguise. enters Zimbabwe in disguise. become marooned at sea aboard a small lifeboat.‘PG’ (CC) (2013) Nicholas Hoult. (CC) to Depravity ’ the Sexplorer” nals plan an elaborate heist in Europe. ’ ‘PG-13’ (CC) Masters of Sex Masters and Masters of Sex “Catherine” Couples Masters of Sex Libby and Masters Homeland “Still Positive” Carrie Homeland “Still Positive” Carrie Movie ›› “On the Road” (2012, Drama) Garrett Hedlund. Premiere. An (4:15) Movie › “Love and Honor” (SHOW) Johnson recruit. are included in the study. rest in Miami. aspiring writer and his new friend hit the open road.‘R’ (2012) Liam Hemsworth. turns the tables. ’ (CC) turns the tables. ’ (CC) Movie “Fear Island” (2009) Haylie Duff. A mysterious Movie ›› “The Frighteners” (1996, Suspense) (4:35) Movie ›› “Man on a Ledge” (2012, Suspense) (:20) Movie ›› “Step Up Revolution” (2012, Drama) Movie ›› “The Frighteners” (1996) Michael J. Fox. Premiere. A psychic (TMC) killer terrorizes five students on an island.‘NR’ Michael J. Fox, Trini Alvarado. ’ ‘R’ (CC) Sam Worthington. ’ ‘PG-13’ (CC) Ryan Guzman. ’ ‘PG-13’ (CC) hustler encounters a genuine supernatural threat. ’ ‘R’ (CC)
CLASSIFIED
Page E8• Saturday, November 9, 2013
Northwest HeraldSaturday, / NWHerald.com November 9, 2013 “Sunset in Glacial Park” Photo by: Kevin
Upload your photos on My Photos – McHenry County’s community photo post! Photos on My Photos are eligible to appear in print in Northwest Herald Classified. Go to NWHerald.com/myphotos
BAR STOOLS - Quality set of 3 durable hardwood w/ larger seating area than your regular bar stool, classic style and casual comfort, perfect for your kitchen island or breakfast bar. Excellent $95. 815-477-9023 HOLIDAY DINNERWARE SET – Royal Seasons Snowman Dinnerware Set. 71 piece. $50. Call anytime, 815-861-9864.
Humidifier/Bionaire Adjustable timer, humidity settings, one room or large area, new filter, $15. Space Heater/DeLonghi sealed radiator style, multiple electric and heat settings on castors $15 815-455-5903 Ice Cream/Sherbert Cups Stainless Steel on Pedestal 35 Total - $15 815-790-8213 INDOOR GRILL - George Foreman Lean Mean Fat Grilling Machine. Interchangeable griddle plate & waffle plates. $30. Call 224-587-7522 or email: buyclassified@yahoo.com to arrange pickup. LADDER - Cosco 17' - World's Greatest Ladder. In great shape like new. Has 3 positions as a step ladder, 6 heights as an extension ladder, 3 positions as a stairway ladder, 2 heights as a scaffold, & 2 heights as a wall ladder. $100. To arrange pickup, 224-587-7522 or email buyclassified@yahoo.com. Lamps – Very Nice Table Lamps $5. 815-385-4400 MILK GLASS GRAPEVINE PATTERN Milk Glass Grapevine Pattern Snack Sets. Condition is excellent. Pattern features grape & grape leaves pattern. Snack plate is about 10 1/4" long X 8 1/4" wide. Cups are about 3" tall. $5 per set/total of 15 sets. Call 224-678-7333 ask for Cindy. MINI-SCREEN DOOR - "HOME SWEET HOME", handcrafted decor, very unique & one of a kind wooden antiqued screen door plaque brings the outdoors inside!!! 17"h x 8"w. $15. 815 477-9023. Mirror-Entry Hall gold plated Beveled 66”x 26”. $100. 815-385-4353 Mirror. White wood frame. 36x36” Very good condition. $20. 815-455-6627
Lawnsweeper by Craftsman 42” - Great Shape - $225 815-459-6721
LUGGAGE 3 Pc Samsonite Set w/wheels. Never Used. $50 OBO. Call anytime, 815-861-9864.
ORTIZ LANDSCAPING
Pictures- Assorted framed art. Small- Lrg. $20 - $50. 815-861-1163
SNOW REMOVAL & CLEAN UP Mulch, brick patios, tree removal, maint work. Insured. 815-355-2121 RAKE & VACUUM - Toro Electric Blower/Vac is also a leaf shredder. Comes w/ blower tube, 2 vacuum tubes, & bag. $35. Email buyclassified@yahoo.com or call 224-587-7522 to arrange pickup. Wheel Barrow. Large. $25 815-861-3270 after 4pm.
Goose ~ American Buff Rare, tame, young, quiet, beautiful color, $20. 815-648-2501 Call early AM or after 8PM
DRILL - NEW SEARS 1/2" CORDLESS DRILL 19.2 VOLT WITH LED LIGHT & CASE. HAS 2 GOOD USED NI-CAD BATTERYS AND CHARGER. $60 FIRM. 815-675-2155
Electric Motor 15HP, 1200 RPM, 220 Volts. $75. 815-675-2462 GENERATOR - Kohler 12 hp 5000 watt. Nice older unit, runs great also has electric start, needs new gas tank or clean this one. $400 firm 815-675-2155
GENERATOR ~ COLEMAN 5000 Watt, $400/OBO 815-385-5145 Lv Msg
GENERTOR
4500 Watt Onan, $350. 815-385-5145 Lv msg Joiner/Planer – 6” Craftsman Extra Knives & Knife Setting Gauge Excellent Condition - $160 815-943-3159 Leigh Dovetail Jig Model D3-24” $150 815-378-2201
Power Trowel Marshaltown 30” combo blades & floor grinding attach. great running machine, $300. 815-385-5145
POWER WASHER
Painting Lighthouse
2700 PSI $150/obo. 815-479-1000
Painting Nature Scene
SAW DeWalt 10” radial arm saw $90 Union 815-923-8009
$20
815-385-3269
Beautiful lake. 36X33. Wood frame, $20 815-385-3269 Restaurant Dessert Plates Home-Laughlin, Plain White, 50 Total - $20. 815-790-8213 Restaurant Dishes – 27 Buffle China, Saucers Plain - $10 815-790-8213 Restaurant Plate Cover Warmers 40 Standard Size – Round, Stainless Steel Covers - $45 815-790-8213 Restaurant Salad Plates – Clear Glass, Libbey Duratuff – 50 Plates 7-1/2” - $30. 815-790-8213 Salad or Dessert Size Dishes 64 Pieces, Buffalo China, Scalloped Edge, Plain White $35. 815-790-8213 Set of China: Vintage Sango Japan, 92 pieces, white with blue/brown design around edges, service for 10. Good condition. Can email pictures. $150 or best offer. 815-568-0671 Shenango O'China Salad Plates 42 Total w/ Cream Border & Emblem - $20. 815-790-8213 TABLE TOP STONE FOUNTAIN Includes pump & adapter. $10. 224-587-7522 or email buyclassified@ yahoo.com to arrange pickup.
TABLE SAW ~ Professional Craftsman - tilting arbor, 3' x 5' table w/lock wheels, 10” slide - guides, $150 OBO. 815-479-0492
Hospital Bed – 5 yrs. old Good Condition - $100 OBO, Call Robin 815-337-0749
HOSPITAL BED
PORTABLE HEATER
Portable, Natural Gas, Salimander Heater w/ hose. $60. 847-476-6771
RC Helicopters (2)
Fly indoors or out, includes radio and chargers, $99/obo. Makes Great Christmas Gift! 815-382-3952 Shop Vac. $25 815-861-3270 Stained Glass Equipment - Tools, Grinder, Glass, Books, Supplies to make any project. $200. Best Time To Call: 9am-6pm. 815-653-7619 Swimming pool solar cover 12x24 brand new in the package $50 224-569-3903
AIR HEATER
Snowblower Craftsman Eager No. 1. 20” cut, 5Hp., Forward. Reverse, Self Propelled, Tuned & Ready, $200. 815-479-0492
WINDOWS
Older with frames, triple track storms and screens. Starting at $25. 847-421-5751
* 2 Powered Speakers Yamaha MSR100, $175/ea * (2) Stage Stands $50/ea * Handheld mic & receiver Audio-Technica $150 CALL BUD 224-569-6463
DRUM HEAD
Cab700 International Dynamax with carrying case, $75. 847-515-8012
BIRD FEEDER Metal Yard Art
similar Frank Lloyd Wright, Oriental Style, 6ft, $250. 815-578-0212 CERAMIC TILE FRUIT SIDE TABLE Makes an artistic statement w/ vibrant, detailed hand painted tile to bring that splash of color to your backyard or sunroom. Attractive Verdi green patina finish. 13.5”sq. x 18”h. Excellent condition. $45. 815 477-9023.
815-334-8611
Craftsman Yard Vacuum - Great for cleaning up the fall leaves Asking $150. 847-658-5104 LAWN MOWER - 19" Neuton, used, battery powered. Includes mulching plug & lawn clipping bag. Added attachments: weed trimmer, 2 replacement trimmer spools, new replacement blade & striper, 2 batteries & their chargers & extra new charger. $400. email buyclassified@yahoo.com or 224-587-7522
LAWN MOWER
Black & Decker electric, works great, $100/obo. 847-669-0144
LAWN MOWER ~ RIDING
Snapper Hi-Vac, rear bagger, 12HP, Briggs & Stratton. New battery, runs great, $200. 815-351-8216
CL Bailey Pool Table, blue felt like new, claw feet, slate, $1200, you haul 4 Corvette stock rims, 6 tires, $700 815-355-5143
FRAMED BOARD WITH CUBBIES Great for Storage or Display Merchandise in a store. Corkboard measures 23 H x 15 W w/ 3 cubbies 5 W x 3.5 D & 4 antiqued hooks. Pottery Barn inspired, framed in satin black, like new condition. $35. 815 477-9023
See Pix at estatesales.com
CRYSTAL LAKE PICKERS/ CLEANOUT SALE
ONE DAY SALE ONLY SAT, NOV 9 9AM - 4PM #'s @ 8:00 CASH ONLY (No Bills Over $50) 361 EVERETT AVE. Tools, Furniture, Vintage Toys, Holiday décor, Appliances
Golf Clubs (3 sets). Incl bags. $50/all OBO 815-455-6627
HUNTLEY
HM-88 with cover, excellent cond! $15. 815-444-9820 TOBAGGAN - Vintage Toboggan Sled by Adirondack Industries, 94 L x 18 W, very little use, in excellent condition, ready to be enjoyed by the whole family or add to your decor! $275. 815 477-9023
2much2list
AMERICAN GIRL DOLLS
Molly and Kirsten doll with outfits. Great condition! $150 each. Please Call 815-814-8863 Melissa
BOARD GAME
Ford F150 STX Power Wheels Monster Traction - New battery end of June - New $389, Asking $175.00 - Cash And Carry 847-658-5104 White, comes with food and all accessories, battery operated, one owner, excllent condition! $99. Zhu Zhu Pets, full collection of whole set, $75. 815-477-8485
Little Tykes Cube Slide – Adventure Climber - 31” sq. - $25 815-790-8213 WOODEN TOY BOX - Amble storage, nice piece $25. 815 477-9023
Antique and Modern Guns Old Lever Actions, Winchesters, Marlins, Savages, etc. Old Pistols and Revolvers. Cash for Collection. FFL License 815-338-4731
Lionel & American Flyer Trains
McHenryCountySports.com is McHenry County Sports
Christmas Tree
Having a Birthday, Anniversary, Graduation or Event Coming Up?
5 ft, lights, ornaments and misc decorations, $25/obo. 847-515-3986
Share It With Everyone by Placing a HAPPY AD!
Christmas Tree Green, 7.5 ft, $55.00. 847-736-2838 Follow Northwest Herald on Twitter @nwherald
Northwest Herald Classified 800-589-8237
3705 WEST ELM FRI 11-7 & SAT & SUN 8-5
FRI, SAT, SUN NOV 8, 9 10 10AM - 5PM
Admission $3 Bring Ad for $1 Off
EVERYTHING MUST GO!!
Antique Bedroom Set, Dining Room Table Four Chairs, Day Bed, Sectional Sofa, Like New Wicker Patio Furniture LG Flat Screen TV, Honda Odyssey Van More Information and Pics Click on “View Sales”
MCHENRY
SALE JUKE BOXES SLOT MACHINES ADVERTISING PRIMATIVES Kane County Fairgrounds
4508 SPRING GROVE ROAD
SHEPHERD OF THE PRAIRIE LUTHERAN CHURCH
Old Farm House & Garage Loaded!
estatesales.net
WOODSTOCK BULL VALLEY GREENS
1018 Harrow Gate Dr. Fri. 11/8 Sat. 11/9
9AM-5PM 9AM-3PM
Wonderful Sale Everything Like New! Leather Couch, Chair. Sectional Couch,Qn Bedroom Set, Lg. Flat Screen TV, Office Furn, Wicker Set, Singer Featherweight, Teacher Materials, Motorcycle Helmets/Jackets, Fishing, Golf, Treadmill, Elliptical, Mens Clothes XL-3X & Much More! CASH ONLY! #'s @ 8:30 See estatesales.net All NIU Sports... All The Time
Wide range of quality items in good condition from Vintage to New. Men and Women's clothing (i.e. Polo / Orvis), winter coats and accessories, ice skates, Home/ Office furnishings, household and holiday decor and much MORE! Special FREE to a good home rack and hot coffee served. CASH OR CREDIT.
CRYSTAL LAKE
10th ANNUAL BAZAAR Fri, Nov. 8 5pm-8pm
THURS, FRI, SAT, SUN NOV 7, 8, 9, 10 8AM - 4PM
150 GATES ST. Corner of Gates & Main Large collection of Coca-Cola memorabilia, furniture, tools, building supplies, 13,000 sq ft building full of items!
HARVARD 702 N. DIVISION GARAGE SALE! Sat. thru Wed. 9am-4pm Chenille Sofa, Dining Rm Table, Coffee Table, Ladders, Tools, Picture Frames, Patio Dining Set, Velvet Victorian Chair, Dishes & Lamps.
HOLIDAY HILLS 2722 Lake Dr
1 Day Moving Sale by Lifestyle Transitions. Saturday 11/9/13, 9am-3pm Household, Garage & Boating Items See EstateSales.Net listing estate-sales/IL/Mchenry/ 60051/532833
LAKEWOOD
SATURDAY NOVEMBER 9th 9AM - 3PM
LUNCH & BAKE SALE 3717 MAIN ST. 815-385-0931
MCHENRY FRI, SAT, SUN 9-4 219 SOUTH DRAPER RD. Misc Furniture, Household décor, Linens, Many Princess House Pieces & Much More! MANY GREAT DEALS!
Wonder Lake WEST SIDE
INDOOR SALE HOLIDAY EXTRAVAGANZA Saturday & Sunday November 9th & 10th 9am – 4pm
3801 Chemung Dr. Pre-lit Trees, Ornaments, Lights, Avon Christmas Plates, Porcelain Dolls, Snow Babies, Villages, Mangers, Lamps, Dishes, Misc Furniture & Much More! PLUS A Retro 30's 4 Pc Bedrm Set, Excellent Condition!
WOODSTOCK 10315 Aavang Rd. Inside Barn
Sat 11/19 8am-4pm Refrigerators, Swing Set, Tools, Lawn Mowing Equipment, Boys & Girls Dress Clothes. Advertise here for a successful garage sale! Call 815-455-4800!
1-800-272-1936 or
NWHerald.com/jobs No Resume Needed! Call the automated phone profiling system or use our convenient online form today so our professionals can get started matching you with employers that are hiring - NOW!
We are At Your Service!
$4 Bag Sale Starts at 1PM
8505 Redtail Dr.
10805 Main St
Clothing, Toys, Books, Household
Huntley
& MUCH MORE!
AT OUR ANNUAL BAZAAR, YOU'LL FIND...
Get the job you want at NWHerald.com/jobs
ALL PROCEEDS GO TO THE DEBT REDUCTION OF THE BUILDING. Be sure to visit our Coffee Klutch Cafe & Bakery Sweet Shop for a free cup of coffee or tea...& maybe purchase a snack for now and something to take home.
CRAFT/VENDOR BAZAAR
SAT, NOV 9 9AM - 3PM
Sat, Nov. 9 9am-2pm
Unique, handcrafted items by members of the church & the Prairie Crafters, a variety of wood, crocheted, knitted & sewn items including eighteen-inch doll clothes, accessories, & holiday gift items. And discounted name brand jewelry. NEW THIS YEAR: A santa secret shop for kids!
FIRST UNITED METHODIST CHURCH
Off of Thompson Rd.
CROSSPOINT LUTHERAN CHURCH
Beautiful Antique BR Set, LOTS of Vintage Wicker & Christmas Conducted by: Park Place Emporium 815-344-9101 Pics Can Be Found @
LARGE SALE SAT. 11/9 & SUN. 11/10 9AM-4PM 9801 BULL VALLEY ROAD
NOV. 13 & 14 WED. & THURS. 8-4 Rain or Shine Indoor Buildings Food Avail. Admission $5.00 630-881-4176 (Booths Avail.)
FRI & SAT NOV 8 & 9 9AM - 4PM
BULL VALLEY
Everything Must Go! Holiday Craft and Vendor Sale on Saturday, November 9 from 9:00 AM-3:00 PM at Cary Park District, 255 Briargate Road
815-353-7668
WANTED TO BUY: Vintage or New, working or not. Bicycles, Outboard motors, fishing gear, motorcycles or mopeds, chainsaws, tools etc. Cash on the spot. Cell: 815-322-6383
ECKEL'S MCHENRY FLEA MARKET
ISLAND LAKE
KITCHEN ~ STEP 2
Leapfrog Phonics Learning System 5 Lesson Plans, Teach your child consonant blends, long vowels, complex vowels. Like New, Perfect for Homeschooling $30. 815-790-8213
CHRISTMAS TREE - 7 ft No lights. Easy assembly. $45. 815-455-6280
162 S. STATE ST. Highway 31
Friday 11/8 & Saturday 11/9 9am – 3pm
*Mary Kay *Tastefully Simple *Perfectly Posh *Usborne Books *Juice Plus+ *Young Living Essential Oils *Scentsy *Wild Tree *31 Gifts *Oragami Owl *Jamberry Nails *Lia Sophia *Chiro One *Miche *Bellaroma *L'Bri *It Works *Funky Things
Windfall Antiques
Info & Pics @ CestateSales.com
3702 LAKEVIEW
It's the most wonderful time of the year, and that means it's time to shop! Stop on out to the Mixin Mingle and get your shop on with the hottest vendors in the area. Our unique gifts and awesome product lines are sure to help you find something for everyone on your list. Plus, just for stopping in, you will get an entry in to our gift basket drawing!!!!!! You could win a gift basket valued at over $250 JUST for stopping in!!!! The first 50 shoppers in the door receive a free swag bag! We are featurning the following vendors:
.
Holiday Craft & Antique Show
One dark blue & one light blue, good condition, $15/ea or $25/both. 815-444-9820
High School Musical Twister game, New, Never Opened, $10. 815455-2689 DISNEY PIXAR CARS 2 EDITION SORRY SLIDERS Board Game, The Game of Sweet Revenge by Parker Brothers. NEW, Factory SEALED! $15. 815 477-9023
CHRISTMAS TREE - 13 ft pre-lit. Most lights working. A few strands out. Light fuse wand will detect & fix. $65. 815-455-6280
Horse drawn buggy, scroll saw, Reliant 18” band saw, radial arm saw, Craftsman table saw & router, air compressor, Delta 10” saw with tables, Craftsman stacked tool box, IH McCormick Farmall Cub, sand blaster & cabinet, wood lathe, ladders, large drill press & table drill press, oversized woodwork bench, Coachmaker's bench vise, cherry picker Oak dresser with mirror, Morris chair, oak highboy, sewing machines, child's play dresser & smalls
DEL WEBB
Traveling Golf Bags - Club Class
Nikon FG 35mm camera with 52mm lens, SB-15 Speedlight, extra macro zoom lens 80-200mm, soft cover and manuals. $100 OBO Call 847-337-1262
Route 14 past Rose Farm Rd.
McNeil Mansion
Sports Equipment $20 - $200. 847-426-9303
ROSS 1 1/2 year old male Brittany There are times when you have to take control of your life. You need straight talk, straight answers and wisdom. You can count on me. 815-338-4400
418 MARAWOOD DRIVE
FRI & SAT 9-4
DOG CRATES (2)
PHILLIP 7 month old male Black & White DSH. I enjoy travel, poetry, long walks on the beach and some jazz. I'm romantic and fun. Looking for someone who loves being in love. 815-338-4400
CASH ONLY
ELGIN
Sleep No# Bed, BR Furniture, Sleeper/Sofa, Secretary, Kitchen Table, Loveseat, Chairs, Tables, China, Many Collectibles, Costume Jewelry, Kitchen Appl: Oven/Stove, Dishwasher, Fridge
LUNA 3 month old female Lab mix I'm cerebral, funny and a major flirt. I have infectious energy when I'm with friends. I do get restless and bored easily. 815-338-4400
FRI & SAT NOV 8 & 9 9AM - 3PM
815-363-3532
ICE SKATES ~ LAKE PLACID
Snowboard boots, kid's size 6, cobalt blue, worn once. $20 815-477-3775
LAXTEX GLOVES
Disposable, case of 1000, very strong, $55. 815-578-0212
Algonquin
12298 Black Oak Trail
DISHES ~ PRINCESS HOUSE PAVILLION 4 piece soup tureen with box (never used), $65. Princess House 2 piece stainless steel domed roaster, $50. Many assorted pieces, mostly Pavillion, $5-$25/ea. McHenry 815-363-0064
590 Lake Plumleigh Way
Black white, litter trained. FREE TO GOOD HOME. 815-276-3827
BEDSPREAD ~ NEW, FULL
With 4 chairs, good condition. $40 815-459-4675
SOMETHING SPECIAL ESTATE SALE Fri-Sat Nov 8 & 9 9a-4p
ironhorseestatesales.com
Tennis Racket - Wimbledon
MCHENRY
MIXIN MINGLE
Men's Dive Size, $400. 815-900-8325
Large Petco, excellent condition for medium size dog, $50/each. 815-477-8485 Feeder mice & rats for your reptiles, from $.50 815-344-7993
2nd Annual Woodstock Holiday Boutique Sat. Nov 9th 9am-2pm
124 Cass Street
Dirt Bike/ATV Helmet. Youth Med. Blue/Black. Good cond. $15 CASH Crystal Lk. 815-477-3775
Scuba Equipment
CAT ~ FEMALE
WOODSTOCK
& MUCH MORE!
Pianos Quality Pre-Owned Pianos Delivered & Warrantied
60” white and carmel swirl, brand new! $75 815-322-3948
Card Table/Folding
TORO #3650-E single stage snow blower, square body style, like new, with electric and 6.5 hp gts engine. $400 firm. 815-675-2155
Ping Pong Table- Harvard Wheelaway Playback - Folds up nice and thin and has wheels for storage - $100 - Call or text: 847-212-5243
MT-45, still in box, $25. 815-455-2689
BASKETS
Cabinet – Large, White, 4 shelves, Wood, 15”W x 49”H x 14”D $35 OBO. 815-568-7793
Snowblower ~ Simplicity
24” Cut, 8HP, Briggs & Stratton Engine, 2 Stage, Includes Electric Start and Tire Chains - $375. 847-587-5017 Snowblower/Lawn Boy 320E 3HP, runs good, $50. 815-508-1114
Keyboard/Casio Tone
Unique, various sizes, $5 - $20. 815-861-1163
54x78”, rich, dark gold floral, $90. 815-459-3822
$50 847-973-2314
Women's, with blade guards, size 6, excellent condition! $20 847-854-7980
Bathroom Vanity Top - ONLY Bird Bath. Concrete. $35 815-861-3270
St. Nicholas. 5' tall. $100 OBO. 847-515-3502 TOPIARIES: Brand new outdoor indoor lighted buck & doe. New. $40. If interested, please email me at buyclassified@yahoo.com or call 224-587-7522 TORO CCR POWERLITE-E 3 hp 16' cut with electric start. and it folds to fit in your car too. Looks and runs well. $225 firm. 815-675-2155
TRAIN AND TRACK BOOK ENDS Adorable kids train engine and caboose moves forward and back along the tracks to make adding books fun. Durable in good used condition. 41"w x 4.5"d x 8"h $30. 815 477-9023
WALKER
Portable, Forced Kerosene. Remington 55, $50. 847-476-6771
Nativity Set. 9 pcs. Painted, plastic, 2-3' tall, lighted. $100 OBO. 847-515-3502 Snowblower & Lawn Mower Both sold As-Is, Worked fine a few years ago, needs oil change $125 for both. 815-679-6178
Power Shovel-Toro electric.
Turntable, CD, Casette player, oak finish, like new, only been used a few times, $55 224-569-3903
ALGONQUIN
Large 32 Gallons of Christmas decorations, worth $1200, sell for $200. 847-804-2999
Swimming pool solar cover 12x24 brand new in the package $50. 224-569-3903
Electric, mattress, lifting bar + all beddng, $175. 815-455-3569 Good Condition! $25/obo. 815-385-6530 WHEELCHAIR Black and chrome, new in box, lightweight, elevating foot & leg rest, 250lb capacity. $100 815-578-0212
CONTAINERS (6)
The Northwest Herald reaches 137,000 adult readers in print every week, and 259,000 unique visitors on NWHerald.com every month.
Call to advertise in the At Your Service directory. Need Help Rebuilding, Repairing or Replanting? Check out the
At Your Service Directory in the back of Classified and on PlanitNorthwest.com/business for a list of Local Professionals.
In the Northwest Herald classified everyday and on PlanitNorthwest Local Business Directory 24 hours a day, 7 days a week.
planitnorthwest.com/business
800-589-8237
classified@shawsuburban.com
CLASS 4A: HAVARD 56, CHICAGO KING 16
PREP FOOTBALL EXTRA
Saturday, November 9, 2013
UNEXPECTED BLOWOUT Harvard’s Isaiah Rudd carries the ball during a Class 4A second-round playoff game against Chicago King on Friday night in Harvard. Harvard defeated King, 56-16. Lathan Goumas – lgoumas@shawmedia.com
Football scoreboard Friday’s result CLASS 4A Harvard 56, Chicago King 16 Saturday’s games CLASS 5A No. 1 Montini (10-0) at No. 9 Marian Central (8-2), 6 p.m. CLASS 6A No. 1 Boylan (10-0) at No. 9 Cary-Grove (7-3), 1 p.m. No. 5 Marmion (8-2) at No. 13 Prairie Ridge (6-4), 1 p.m. Saturday – webcast at McHenryCountySports.com
Harvard dominates King in 2nd round By JOE STEVENSON joestevenson@shawmedia.com
At McHenryCountySports.com • Video highlights in “The Fastest Four Minutes” from the Harvard’s 56-16 victory over King. sec-
ond.
See HORNETS, page 2 EXTRA
INSIDE GOT YOUR BACK: Former Hornets proud to stand behind coach Haak, writes columnist Tom Musick. 2 EXTRA SAVING HIS BEST FOR LAST: Marian Central’s Ephraim Lee on top of his game in his senior season. 3 EXTRA
PREP FOOTBALL EXTRA
Page 2 Extra • Saturday, November 9, 2013
Northwest Herald / NWHerald.com
Former Hornets stand behind Haak HARVARD – Fielding Kalas remembered the bus ride that ticked off his head coach. The year was 1999, and Kalas was a confident offensive lineman for the Harvard Hornets. He and his teammates were on the way to play Stillman Valley, a powerhouse team with a prized college recruit named Pat Babcock. “On the way in, I had my headphones on, and I was talking smack about the other team, and I was saying it out loud because my headphones were on so high,” Kalas said Friday as he watched his alma mater play Chicago King. “And Coach Haak sat me for the first quarter.” Message sent. Message received. “He goes, ‘You ready to go in now?’ ” Kalas said. “I remember pancaking Pat Babcock on the first play. He goes, ‘That’s how you get your head screwed on straight.’ ” These days, Kalas tells the story with a smile. It was easy to find smiles Friday among Tim Haak’s former players. In front of a packed crowd at Dan Horne Field, the Hornets destroyed Chicago King, 56-16, to advance to the IHSA Class 4A quarterfinals. The win pushed Harvard to 11-0, setting a
VIEWS Tom Musick single-season record for victories in Haak’s 29th and final season as head coach. During the game, Haak focused on the players in front of him. All the while, he knew that former players stood behind him, representing each of the decades under his leadership. Matt Streit stood along the fence in front of the bleachers, where he was surrounded by several of his former teammates from the Class of 2008. Streit was part of the last Hornets team that reached the quarterfinals, and he has not missed a home game this season. What made Haak a great coach? “He made me a football player,” said Streit, whose father, Todd, serves as the Hornets’ defensive coordinator. “I went on to play [at Elmhurst College], but I owe most of my career to him and his coaching staff. “He pushes you. He expects you to give 100 percent effort all of the time, and it reflects on the program. You can see how the kids enjoy it, too. You can see how much effort they give. They
respect him, and they give him 100 percent effort.” Meanwhile, Haak’s former players give 100 percent support. Earlier this season, former Harvard quarterback Mike Leyden caught a flight from Florida to see the Hornets play. That’s just one of many examples of the bond that continues long after the final down, the final whistle, the final post-game walk out of the locker room. “It’s always been and always will be our extended family,” said Haak, who has received wedding invitations and baby announcements from his former players. “They come to watch. They support this group. They want them to do well. That’s always rewarding. “Our guys know they’re there. They come on the road. They come here at home. My son [Shane] drove from Madison. He was on the back-to-back quarterfinal team in ’06 and ’07. “Those guys come back from the ’80s, they fly in from Florida. I’m telling you, they are loyal. There’s nobody more loyal than some of our former football players.” Another one of those players is Tyler Streit, Matt Streit’s uncle and part of the class of 1991. Tyler Streit was part of Harvard’s
first team to reach the quarterfinals. He played offensive and defensive line for Haak, who was highly intense and highly intelligent. Little has changed, Streit said with a smile, other than Haak mellowing a bit. “I think every Friday night, our game plan is better than the other team’s,” Streit said. “So if we lack a little bit of physical ability that the other team has got, we make up for it.” And the Hornets win. No wonder Haak’s players keep coming back. “He was kind of like Mr. Miyagi,” Kalas said. “He would teach you one thing about the game that would reflect in life about communication and preparation and working hard and showing up on time, all of those things. “That’s why people come back here who have gone on with their lives. We all come back to support what he believes in and what he teaches us. He teaches you how to be a man – not only how to be a football player, but how to be a man.” • Northwest Herald sports columnist Tom Musick can be reached at tmusick@shawmedia.com and on Twitter @tcmusick.
King done in by early mistakes • HARVARD Continued from page 1 Extra on a Powell.”
Lathan Goumas – lgoumas@shawmedia.com
With Chicago King’s Christian Mallengen in pursuit, Harvard’s Ben Platt runs the ball in for a touchdown during a Class 4A playoff game Friday in Harvard. Harvard won, 56-16.
Harvard shows depth of offense By ANDREW HANSEN anhansen@shawmedia.com HARVARD – When Harvard lost running back Christian Kramer in Week 3 to a shoulder injury, it looked like a huge blow to the Hornets’ offense. Kramer was leading the area in rushing at the time, coming off a 200-yard performance, and was the focal point of Harvard’s offense. The Hornets, though, took it as a challenge, and used Kramer’s absence to develop depth in their offense that is now paying off in the playoffs, including in Friday night’s 56-16 win over King. “We’ve had the same philosophy throughout, we just improved every week,” receiver Justin Nolen said. “We’re just doing what we want to do: run the ball hard, play-action, and work with what the offense gives us.” Fullback Jose Mejia and running back Ben Platt helped fill the void in the backfield, with quarterback
Peyton Schneider and Nolen used more. Now the Hornets’ offense is more than one player, with Mejia’s punishing inside runs, Platt coming out of the backfield for passes, and Schneider and Nolen perfecting their play-action passes to help complement Kramer’s outside runs. Kramer scored on the first play of the game, taking a 58-yard run off tackle, and Schneider and Nolen hooked up for 30- and 42-yard touchdowns in the second quarter. Kramer finished with 136 yards on seven carries and Mejia had 40 yards on eight carries in two quarters. Platt added 61 yards on six carries. Harvard coach Tim Haak said it was the improvement of players such as Mejia, wide receiver/defensive back Fernando Carrera and Schneider that have really made the difference this season. “We knew coming in, for us to play at the level we’re playing, we’re going to have to have kids like Jose,” Haak said. “We knew Christian was going to be there, but
Peyton has improved so much.. A lot of kids from last year have really elevated their play.” One constant for the Hornets has been their offensive line of tackles Adam Freimund and Anthony Milanko, guards Dakota Trebes and Juan Carbajal, and center Kyle Peterson. The group helped pave the way for 282 yards on the ground. Trebes said the line takes being the tone setter for the offense seriously. “You are bascially the heart of the offense,” Trebes said. “You have to get going or you don’t have anything.” After starting as a sophomore last season, Schneider said he is far more comfortable leading the offense this season, finishing 6 for 8 for 93 yards. Schneider said his arm strength has improved, and he has more trust in his line and receivers. “Last year, it was new for me. Making the reads was a lot different,” Schneider said. “Having that experience was a huge help.”
Which teams will be moving on to quarterfinals? TAKE 2
The IHSA football playoffs continue into the second round with local entries CaryGrove, Prairie Ridge and Marian Central looking to extend their respective seasons with victories Saturday. Sports reporters Joe Stevenson and Jeff Arnold discuss. Stevenson: We’ve been a little spoiled in recent years here with the Fox Valley Conference’s football success. Cary-Grove won Class 6A in 2009, Prairie Ridge won it in 2011 and C-G was runner-up again the next year. The first round was rough on the FVC, which was 2-5, but the traditional playoff heavyweights, C-G and Prairie Ridge, survived. We had to make the three-hour drive to Champaign in the past, but the state championships are in DeKalb this year. Can any of these three get us there? Arnold: I’ve only been here
Jeff Arnold and Joe Stevenson face off a little more than a year, but the thing I’ve quickly learned is that the Trojans have a solid system in place that’s built for the long run. I look back to the start of the season when C-G had those two monster games back-to-back against Lake Zurich and Wheaton North and it’s almost like the Trojans got a head start on the playoffs. Now, they seem to be on a roll and I wouldn’t be surprised if they beat Boylan, setting up a potential state quarterfinal meeting with Prairie Ridge next week. Am I reading the situation correctly or am I being overly optimistic here?
Stevenson: I don’t think you’re overly optimistic at all. Guilford coach Mel Gilfillan saw C-G’s speed firsthand last week and thinks it’s a great matchup. He’s the only coach who has seen both this season. It will be a tough task – Boylan’s 49-1 since the 2010 season – but I think the Trojans can pull off an upset. What about Prairie Ridge? The offense did not blow up last week, but the defense came up big. Arnold: The playoffs seem to be all about momentum and carrying things over from the week before. The Wolves have now done that for four straight weeks. The good
news for the Wolves is that quarterback Brett Covalt is back. I’m not taking anything away from Luke Annen, who really took charge of the offense against Lakes. I think the biggest benefit for Prairie Ridge is that Marmion Academy has spent the week trying to figure out how to stop the Wolves’ triple option, which seems to be running as fast and as efficiently as it has all year. Speaking of tall orders, how about the one Marian Central has in once again having to deal with Montini? Stevenson: Montini is so good. I really thought it was Marian’s turn last year, especially after the convincing regular-season victory, but Montini did it again. The Hurricanes should be confident they can score, and they played them tough in a 40-35 loss in Week 7. Marian’s hoping for a little role reversal
from the previous two seasons – lose in the regular season, win in the playoffs. It will take their defense’s best effort. Arnold: OK, we’ve looked at all the positives. Is there a team left you think is susceptible and could be looking at the end of the road today? Stevenson: They’re all underdogs, but I like Prairie Ridge’s chances the best because Marmion’s a little beat up and the Wolves are hot. C-G and Marian each are facing two of the state’s best in the past few years. I like C-G’s chances better than Marian’s, just because Montini is such a great program. Arnold: That’s the thing I love about playoff football. You never know what you’re going to see and I think in all three of today’s games, I think we could be in for just about anything. Should make for an interesting day.
NORTHWEST HERALD FOOTBALL GAME OF THE WEEK No. 5 Marmion Academy (8-2) at No. 13 Prairie Ridge (6-4), 1 p.m. Saturday McHenryCountySports.com’s Lester Johnson breaks down the game: Marmion scouting report Potent offense: Marmion had 456 total yards against Fenton last week, 308 of those on the ground. The Cadets had their way against an overmatched Fenton team in a 39-0 win. They averaged 28.3 points a game for the season. The Cadets will spread the field and give the Wolves some looks they don’t see as much in the FVC. Marmion hopes to get starting TB Jordan Glasgow back after missing last week’s game with a sprained ankle. RB Mike Montalbano and WR Enzo Olabi also are banged up. Junior RB Sean Campbell could see more action because of injuries. QB Brock Krueger was 2 of 2 passing for 148 yards and two TDs last week. He’s thrown for 884, seven TDs and five picks. Glasgow (502) and Montalbano (522) lead the team in rushing. The Cadets average 235 rushing yards and 81 passing a game, but should look to pass more against the Wolves. Opportunistic defense: Over the past 14 quarters, Marmion’s defense has allowed 13 points and scored 18. Prairie Ridge will make Marmion stop its triple-option offense, something the Cadets don’t see in the regular season. They held Fenton to 144 total yards and forced five turnovers in Round 1. The Cadets have 19 interceptions this season, but the Wolves rarely throw. Marmion has allowed only 10.1 points a game, with shutouts the past two weeks. Lineman Joe Talbot joins the two-way players listed above with injuries. Montalbano (LB) leads the team in tackles with 62, followed by Sam Breen with 59. The Cadets must stick to their assignments to defend the option. Prairie Ridge scouting report Option offense clicks: Prairie Ridge has 177 points, 25 TDs and almost 1,700 yards in its fourgame winning streak. The Wolves had only 201 total yards in their 21-14 win against Lakes last week. The triple-option has been effective, with QB Brett Covalt leading the way with 735 rushing yards and 14 TDs. Covalt has been cleared to play against Marmion after taking a shot to the jaw that forced his early exit last week. The Wolves don’t throw much and did not attempt a pass last week. They are not very effective when they do. Zack Greenberg (668 yards, 9 TD), Brent Anderson (617, 3) and Steven Ladd (247, 3) round out the Wolves’ backfield. The Wolves average 25.2 points a game, but it’s 43.7 during their four-game winning streak. The offensive line will be key to a Wolves victory, they will set the tone. Defense builds confidence: Prairie Ridge has allowed an average of 19.1 points a game this season, and 15.2 over the four-game winning streak. Last week the defense kept Lakes from scoring after giving up a 70-yard pass play that left the Mustangs 9 yards shy of a potential game-tying TD. That stand should give the Wolves some confidence. It will be up to the line to get pressure on Krueger and force him to make quick decisions. The defensive backfield should get plenty of action and chances. Although the Cadets spread the field and want to test the Wolves through the air, the numbers show that they still run plenty. Final word The Wolves knocked the Cadets out of the playoffs in 2007, 2009 and 2011. I’m sure Marmion would like to return the favor. It comes down to the spread versus the triple-option on offense, and which of these two solid defenses plays better. Many times injuries, turnovers and special teams make the difference in a close game. Lester’s pick: Prairie Ridge 20, Marmion 14 Lester’s other picks Boylan at Cary-Grove: Boylan by 7 Montini at Marian Central: Montini by 7
PREP FOOTBALL EXTRA
Northwest Herald / NWHerald.com
Saturday, November 9, 2013 • Page 3 Extra
CLASS 7A: BOYLAN AT CARY-GROVE, 1 P.M. SATURDAY
Winning programs clash Trojans’ tradition
By JOE STEVENSON joestevenson@shawmedia.com CARY – Cary-Grove makes the football playoffs every season with more expectation than hope of sticking around for a while. The Trojans started a current string of 10 consecutive playoff appearances in 2004 when they advanced to the IHSA Class 7A state championship game. C-G has won its first-round game every year of that streak and is 7-2 in second-round games. That’s a trend the No. 9-seeded Trojans hope continues when they host No. 1 Boylan (10-0) in a Class 6A second-round playoff game at 1 p.m. Saturday at Al Bohrer Field. “We hop on being consistent in the offseason and we know that consistency in the offseason kind of carries over to the season,” Trojans linebacker Emerson Kersten said. “Giving a consistent effort every day, never taking plays off, is what it’s all about.” C-G will be meeting a Boylan team that has won 13 of its past 14 playoff games. The Titans won the Class 6A state championship in 2010 and won Class 7A in 2011. C-G’s longer history, a 24-8 postseason record since 2004, is quite impressive itself. “It’s a combination of so many factors and it all probably comes down to our kids buying into our system,”
Cary-Grove has displayed a great postseason tradition since the 2004 season with a 24-8 record. Year Class Opponent Result 2004 7A Woodstock W, 27-20 Belvidere W, 21-14 CL South W, 34-0 Morgan Pk. W, 21-14 Libertyville L, 13-3 2005 6A Freeport W, 48-21 Prairie Ridge W, 28-0 CL South L, 20-14 2006 6A Oak Lawn W, 49-7 CL South W, 28-0 Batavia L, 15-14 2007 7A Woodstock W, 30-0 De La Salle L, 27-26 2008 7A Guilford W, 47-0 St. Chas. E. W, 10-7 CL South L, 14-7 2009 6A St. Viator W, 57-21 Highland Pk W 42-28 De La Salle W, 42-0 Prairie Ridge W, 40-7 Providence W, 34-17 2010 6A Hubbard W, 28-20 Robeson W, 35-0 Boylan L, 20-14 2011 6A CL Central W, 14-7 Nazareth L, 24-0 2012 6A Auburn W, 41-7 St. Patrick W, 49-21 CL Central W, 7-0 Lake Forest W, 42-21 Crete-Monee L, 33-26 Trojans coach Brad Seaburg said. “That encompasses our weightroom, our summer program, our leadership meetings.
“You look at the whole big picture and there’s not one piece of it that’s all the answer together. That’s really been the measure and consistency. I don’t know how to explain it, it’s all part of the program.” C-G, like many teams, brings up some freshmen and sophomores for the playoffs. Linebacker Matt Hughes says that has a profound effect on younger players. “A big part of it is we bring up the sophomores and freshmen during the week they give us a really good look and helps us focus,” Hughes said. “It pulls the team together and builds camaraderie. Everyone is one big team fighting for the same thing together.” Watching quarterfinals, semifinals and state title games – the Trojans have been in three in nine seasons – may inspire those younger players during the next offseason. “With the efforts we put in in practice we set ourselves up to be in that position in the postseason,” Kersten said. “It’s kind of what we expect all season long.” Seaburg said bars of achievement are set and raised constantly, which plays an integral part in the playoff mindset. “Everyone has the expectation to go as far as we can and win as many games as possible,” Hughes said.
CLASS 6A: MARMION AT PRAIRIE RIDGE, 1 P.M. SATURDAY
Wolves streak into 2nd round By JEFF ARNOLD jarnold@shawmedia.com Dan Thorpe loves the challenge that comes with playoff football preparations when tackling the unknown becomes top priority. But the Marmion Academy coach readily admits that trying to get a handle on Prairie Ridge’s triple-option offense has given him a serious headache. Not only is the Wolves’ run-happy attack the complete opposite of the spread schemes the Cadets are used to seeing, but trying to simulate it in the days leading up to Saturday’s 1 p..m. Class 6A second-round playoff game hasn’t been easy. Thorpe has resorted to taking the football out of the equation, coaching his players to cover their assignments rather than trying to guess where the ball may be going. He has shifted speedy running backs to quarterback to give his defense a better look at what it will face against Prairie Ridge. But as the architect of the Wolves’ offensive game plan, coach Chris Schremp admits that figuring out where the ball is going is only half the battle. “With our offense, there’s timing involved and it takes a long time to get that timing down,” Schremp said. “Then you talk about speed and that’s the next thing involved and that’s the other thing defenses have trouble with. “That’s something we’ve got on our side.” As a team that hasn’t been overly successful in dealing with the triple option and that has lost three times (2007, 2009, 2011) in the playoffs to the Wolves, Marmion understands things won’t get any easier Saturday. The Cadets have several key players, including linebacker and leading tackler Mike Montalbano, slowed by injury. For Thorpe, though, at-
Candace H. Johnson for Shaw Media
Prairie Ridge’s Brent Anderson avoids the tackle by Lakes’ Nick Battaglia in the third quarter last week in Lake Villa.
Webcast Visit McHenryCountySports. com at 1 p.m. Saturday to watch a live webcast of Prairie Ridge’s game against Marmion. tempting to game plan for a new challenge is when the real fun begins. “That’s what gets your juices flowing,” Thorpe said. “Hopefully, the kids pick up on that energy of trying to deal with something different. “But once you reach the playoffs, it’s about what you do. So rather than trying to worry about what they do so much, it’s about what you do.” Prairie Ridge (6-4) has won four straight games and continued to roll on offense last week against Lakes when all of the Wolves’ 61 offensive plays came on the run. Despite losing quarterback Brett Covalt to an injury in the second quarter, the Wolves managed to score just enough and then make a late defensive stand to move on. Covalt has been cleared to play after he was deemed concussion-symptom-free in a medical examination Nov. 2. In the win over Lakes, five
different ball carriers split the workload as Covalt, running backs Zack Greenberg and Steven Ladd, along with backup quarterback Luke Annen, all had double-digit carries. With so many offensive options that have all become effective over the past month, Thorpe knows that stopping the Wolves requires as much deception on his part as the Wolves rely on. “You have to be able to confuse the coaching staff in what you’re doing defensively and, therefore, you have to confuse the quarterback,” Thorpe said. “They’re so well coached that the players know a variety of defenses and they’re able to audible to a different blocking scheme or to a different play. It’s tough to prepare for that.” But despite how well the Wolves are playing on both sides of the ball, Schremp won’t allow his team to get complacent. Starting Saturday with Marmion (8-2),each week brings new challenges. “[The wins] are huge, but we have to go week by week,” senior offensive lineman Shane Evans said. “We’ve got to go 1-0 (against Marmion) and if we do that, we can make it to the next game.”
Sarah Nader – snader@shawmedia.com
Marian Central’s Ephraim Lee carries the ball against Montini on Oct. 11 in Lombard. Marian will host Montini on Saturday in a second-round playoff game.
MARIAN CENTRAL
ON TOP OF HIS GAME Young senior Lee leads Hurricanes into action By JOE STEVENSON joestevenson@shawmedia.com Marian Central football coach Ed Brucker offered some important news to running back Ephraim Lee as he walked to practice one day last week. “We’re going to redshirt you and have you play another year,” Brucker said. Lee smiled, knowing he likely will be carrying the ball for some NCAA Division I school next year, with his high school eligibility exhausted. Age-wise, however, it would work. Lee celebrated his 17th birthday Sunday, meaning there are juniors at Marian days and months older than him. It’s no wonder Brucker wants to hang on to Lee, a speedy 6-foot-2, 195-pounder who is second in the area with 1,119 yards rushing. No. 9-seeded Marian (8-2) hosts No. 1 Montini (10-0) at 6 p.m. Saturday at George Harding Field in an Class 5A second-round playoff game. “He’s taken more or a leadership role this season and he’s going both ways [offense and defense] now,” Brucker said. “His running has really improved too, he’s cutting better. He’s seeing the holes and getting downhill.” Lee’s mother, Linnel
Allen, sent her son to school early, which makes him a young senior. “One school tried to hold me back because I was too young for first grade, so my mom sent me to a different school,” Lee said. Lee has handled things well physically and in the classroom. He rushed for 1,323 yards and 15 touchdowns last season on Marian’s 11-1 team. He also carries a 3.7 GPA and scored 28 on the ACT. Lee averages 6.8 yards a carry and has 20 touchdowns for the Hurricanes. He scored on a 67-yard run on Marian’s first play in last week’s 42-8 victory at Bremen. “It’s been really good [this season],” Lee said. “The offense has always managed to put up points for our team. We’ve been able to execute and run our plays, our line has been doing amazing. I feel like our offense has done really well and our team has done really well.” Brucker refrained from using Lee on defense until Week 6 against St. Francis. Now, Lee also plays safety. “We tried [to not play him on defense]. That’s why we went with what we did in the beginning,” Brucker said. “We just decided we couldn’t do it. We have a number of skill position kids going both
ways now.” Lee was fine with becoming a two-way player. “Whatever the coaches want me to play, that’s what I’ll play,” Lee said. “Whatever helps us get the win. I actually kind of like it a lot, being able to hit some guys instead of always being hit.” Marian’s players appreciate what Lee brings to the team, especially without star quarterback Chris Streveler, who is at Minnesota. “He’s more of a leader this year,” offensive tackle Nate Patterson said. “Last year, Strev was the glue and everything. Ephraim’s stepped up a lot, not only in the way he’s running, but being a vocal leader.” Lee plans on majoring in engineering in college and has Harvard, Yale and Holy Cross at the top of his list. He is compiling a highlight video and will send that to more coaches sometime soon. First, he will try to lead the Hurricanes past their nemesis the last four years in the postseason. Marian lost at Montini, 40-35, in Week 7. “We knew it was going to happen,” Lee said. “We have to prepare as always. Montini’s the four-time state champion. I feel like it’s going to be a good game, it always is. And we’re going to play our best and get a win.”
CLASS 5A: MONTINI AT MARIAN CENTRAL, 6 P.M. SATURDAY
They meet again in playoffs By JOE STEVENSON joestevenson@shawmedia.com WOODSTOCK – There is an inevitability to every football season for Marian Central and Montini. “If you get two years on varsity, you’re going to play [Montini] four times,” Marian wide receiver-defensive back Tom Klinger said. Since 2004, the only seasons the two have not met in the playoffs were in 2005 and 2008, when Marian missed the postseason. The Hurricanes trail in the rivalry over that span, 6-11, but they get another shot at 6 p.m. Saturday. No. 9 seed Marian (8-2) hosts No. 1 Montini (10-0) in a Class 5A second-round playoff game at George Harding Field with hopes of ending the Broncos’ streak of postseason success between the Suburban Christian Conference powers. Montini knocked the Hurricanes out of the playoffs each
of the past four seasons and went on to win a state championship each time. “We didn’t get it the first time, but we weren’t too disappointed in the way we played,” Hurricanes offensive tackle Nate Patterson said. “We played hard, put up some points, we just have to tighten up the defense and keep doing what we did last game and improve on a few things.” Marian lost at Montini, 4035, in Week 7 of the regular season. Marian hopes it can produce a turnaround from the past two seasons, when it beat Montini in the regular season, then lost in the playoffs. “If we were to lose a game, it was the perfect way to lose in the regular season because it gives our team confidence, and gives them a sense of security that they feel they can romp us,” Klinger said. “Maybe we come out with some new defensive backs and see what
we can do with our defense and turn the tide a little bit.” Marian has confidence that it can score with quarterback Billy Bahl, the area’s passing leader, and running back Ephraim Lee, the area’s No. 2 rusher. What the Hurricanes will need is a way to slow down Montini’s offense. “We have to get a couple more defensive stops,” Hurricanes coach Ed Brucker said. “The least they scored all season was 21 in the first game. Hopefully our offense will play as well as it did last time.” While Marian wants to toss some new looks at Montini, Marian knows the Broncos will switch things up as well. “They come out in regular season and they’re one team, then come out in the playoffs and they’re a whole other team,” Klinger said. “You have to expect them to be the best team you’re going to play and come out and play the best game you can.”
SECOND-ROUND PLAYOFF PREVIEW CAPSULES Class 5A
Class 6A
No. 5 Marmion (8-2) at No. 13 Prairie Ridge (6-4)
No. 1 Montini (10-0) at No. 9 Marian Central (8-2)
No. 1 Boylan (10-0) at No. 9 Cary-Grove (7-3)
When: 6 p.m. Saturday Where: George Harding Field About the Broncos: Montini has won four consecutive Class 5A state championships and knocked Marian out of the playoffs each of those seasons. QB Alex Wills has completed 114 of 176 passes for 1,651 yards with 17 TDs and four interceptions. WRs Tyler Tumpane (44 catches, 549 yards, six TDs) and Leon Thornton (33, 633, eight) lead the Broncos in receiving. DL Dylan Thompson (6-5, 280) has 13 tackles for losses and committed to Ohio State. About the Hurricanes: Marian QB Billy Bahl has completed 147 of 253 passes for 2,352 yards and 28 touchdowns with 10 interceptions. RB Ephraim Lee has rushed for 1,119 yards and 20 touchdowns. WRs Brett Olson (43 receptions, 898 yards, 12 TDs) and Tom Klinger (32, 459, seven) lead the Hurricanes in receiving. Up next: The winner meets the winner between No. 5 Kaneland (9-1) and No. 4 Joliet Catholic (9-1) in the quarterfinals.
When: 1 p.m. Saturday Where: Al Bohrer Field About the Titans: Boylan is 49-1 since the 2010 season with back-to-back state titles in 2010 (Class 6A) and 2011 (Class 7A). QB Demry Croft has rushed for 520 yards and thrown for 1,445, with 14 touchdowns and one interception. RB Nicholas Pumilia has 659 yards rushing. WRs Brock Stull (39 receptions, 495 yards, six TDs) and Ryan Stanicek (34, 392, five) lead Boylan in receiving. About the Trojans: FB Tyler Pennington leads C-G with 902 yards rushing in seven starts. QB Jason Gregoire (482), RB Matt Sutherland (382) and RB Zach McQuade (237) are the other top rushers. C-G has been in the playoffs 10 consecutive seasons and won its first-round game every time. The Trojans are 7-2 in second-round games during that stretch. Up next: The winner meets the winner between No. 5 Marmion (8-2) and No. 13 Prairie Ridge (6-4) in the quarterfinals.
When: 1 p.m. Saturday Where: Prairie Ridge Athletic Stadium About the Cadets: Marmion coach Dan Thorpe termed his team’s injury situation “not good at all,” coming into the game. LB-RB Mike Montalbano, DL Joe Talbot, LB-WR Enzo Olabi and RB-DE Jordan Glasgow are all banged up. Montalbano leads the team in tackles. Thorpe said Glasgow is most likely to play with a sprained ankle. Montalbano and Glasgow are the Cadets’ leading rushers, with about 500 yards each. About the Wolves: Prairie Ridge has won four consecutive games, all from must-win situations, to reach the second round. The Wolves beat Marmion in 2007 (41-16), 2009 (31-7) and 2011 (49-0) in the playoffs. QB Brett Covalt was hurt in last week’s 21-14 victory at Lakes, but should be back in the lineup. He leads the Wolves with 735 yards rushing. FB Zack Greenberg has 668 yards and RB Brent Anderson has 617 yards. Up next: The winner meets the winner between No. 1 Boylan (10-0) and No. 9 Cary-Grove (7-3). – Joe Stevenson, joestevenson@shawmedia.com
Page 4 • Saturday, November 9, 2013
Northwest Herald / NWHerald.com
A publication of the Northwest Herald Saturday, November 9, 2013
Names and faces that you know
Have news to share? Visit NWHerald.com/neighbors/connect
Fully vested
COMMUNITIES
Johnsburg Police officers Kelly Schmitt (not pictured) and Kevin Del Re (left) visited Ringwood School’s first-graders to talk about stranger danger. Pictured is Del Re letting first-grader Isaiah Ewell try on his vest.
COMMUNITY CALENDAR NOVEMBER
9
Need something to do this weekend? Use the Community Calendar to find fun events that will get your family out of the house. Page 2-3
Algonquin.....................................5 Cary...............................................5 Crystal Lake....................5, 6, 7, 8 Garden Prairie..............................8 Hebron...........................................6 Huntley..........................................7 Johnsburg.......................7, 8, 9, 10 Lake in the Hills...........................10
Marengo.....................................7 McHenry..................10, 11, 12, 13 Richmond..................................12 Ringwood............................12, 13 Spring Grove.............................13 Union....................................14, 15 Wonder Lake.......................13, 15 Woodstock................................14
WHERE IT’S AT Birthday Club...........................4 Campus Report......................14 Community Calendar.........2, 3 Community Spotlight.............3
Northwest Herald / NWHerald.com • Saturday, November 9, 2013
| Neighbors
2
November Nov. 9 • 9 a.m. to noon – Recycling drive, Metra Station parking lot, 4005 Main St., McHenry. Environmental Defenders of McHenry County will accept fluorescent tubes, Styrofoam, electronics and batteries. Televisions and computer monitors accepted for a donation of $10-$35. Information: 815-338-0393 or. • 9 a.m. to 1 p.m. – Stuff the Trailer food drive, fifth annual, east of Wonder Lake State Bank on Hancock Drive, Wonder Lake. The Wonder Lake Water Ski Show Team and Master Property Owners Association will accept nonperishable food, personal items and monetary donations to benefit the Wonder Lake Neighbors Food Pantry. Information: 815-814-4707. • 9 a.m. to 3 p.m. – Rummage sale, Crosspoint Lutheran Church, 8505 Redtail Drive, Lakewood. Information: 815-893-0888 or www. crosspointlakewood.org. • 10 a.m. – Social Security seminar, Crystal Lake Public Library, 126 Paddock St., Crystal Lake. Tom Boehmke of TAB Financial Services will show you how to maximize Social Security benefits. Free. Registration and information: 800-817-3286.58-9105.• 10:30 a.m. – Woodstock Garden Club Girlfriends’ Brunch, fifth annual, Woodstock Country Club, 10310 Country Club Road, Woodstock. Holiday floral design ideas by Jennifer Hunt. Themed gift basket raffle. Tickets: $30. Tickets and information: 8156-338-3446 or. com. • Noon to 2 p.m. – “Get Covered Illinois” presentation and assistance, Wonder Lake Chamber of Commerce, 7602 Hancock Drive, Wonder Lake. Hosted by the McHenry County Department
GET LISTED! Do you want your club or organization event listed in our Community Calendar? Send your submission, complete with event name, time, location, cost and contact information to neighbors@nwherald.com. For information, call Barb Grant at 815-526-4523.
of Health. Counselors will be on hand. Information: 815-728-0682 or.
Nov. 10 • 9:30 a.m. – Lifetree Café, Immanuel Lutheran School Library, 300 S. Pathway Court, Crystal Lake. Personal histories will be explored. Free. Information: 815459-5907. • 10 a.m. to 1 p.m. – Ladies Auxiliary brunch, Polish Legion of American Veterans Post 188, 1304 Park St., McHenry. All-you-can-eat buffet. Cost: $7 adults, $3 children younger than 10. Proceeds benefit hospitalized veterans. Information: 81-5385-9789. • 1 to 5 p.m. – Fox Valley Rocketeers club launch, Hughes Seed Farm, on Dimmel Road, west of Woodtsock. Model rocketry launch. Information: 815-3379068 or. • 1 to 6 p.m. – Marengo Snowgoers annual fundraiser and brat fry, Water’s Edge Golf Course, 4005 N. Route 23, Marengo. Family fun event featuring a 50/50 drawing, raffle and snowmobile information. Information: 815970-1280. • 2 p.m. – Marine Corps League McHenry County Detachment No. 1009 birthday gathering, Chain O’Lakes Brewing Company, 3425 Pearl St., McHenry. Casual dress. Information:. Registration: ruffnermb@aol.com. • 4 p.m. – McHenry Junior Warriors Pom and Cheer Showcase Extravaganza, McHenry West High School, 4724 W. Crystal Lake Road, McHenry. Gift basket display and raffle. Raffle tickets:
$1-$20. Competition routine performances begin 5:30 p.m. Admission: $5 a person, free for children 3 and younger. Information: www. mjwpomandcheer.org. • 5:30 p.m. – Free Sunday community Thanksgiving dinner, First United Methodist Church, 3717 W. Main St., McHenry. No reservations required. Information: 815-385-0931.
Nov. 11 • 9:30 a.m. – Fox Hills Music Teachers Association meeting, First Congregational Church, 461 Pierson St., Crystal Lake. Featuring a “Beethoven: His Sonatas and Smaller PIeces in a Pianist’s Life Today” presentation by Julian Dawson. Information: 847-5157905 or. • 1 to 2 p.m. – Chair yoga class, University of Illinois Extension Auditorium, 1102 McConnell Road, Woodstock. For seniors offered by McHenry County Home and Community Education with yoga instructor Lisa Matras. Free. Information: 815-338-3737.
Nov. 12 • 6 to 9 a.m. – Cholesterol screenings, McHenry County Department of Health, 100 N. Virginia St., Crystal Lake. A 12-hour fast required. Cost: $35. Appointments and information: 815-334-4536 or. • 9 to 10 a.m. – Long-Term Care Planning Series coffee talk, Huntley Park District Rec Center, 12015 Mill St., Huntley. “Paying for the Care Needed: VA/Medicaid/ Medicare/Social Security.” Free. Registration and information: 630377-3241 or invite@strohscheinlawgroup.com. • 10 to 11 a.m. and 7:30 to 8:30 p.m. – “Get Covered Illinois” presentation, McHenry Public Library, 809 N. Front St., McHenry. Hosted by the McHenry County Department of Health. Counselors will be on hand. Information: 815385-0036 or. • 1 p.m. – McHenry Senior Citizens Club meeting, McHenry Township Hall, 3703 N. Richmond Road, McHenry. Guitar musical entertainment by Tom Morris. Refreshments. Visitors welcome.
Information: 847-587-5149. • 6 to 7 p.m. – Open house, Wonder Lake Neighbors Food Pantry at Nativity Lutheran Church, 3506 E. Wonder Lake Road, Wonder Lake. Tour the facility, meet the staff and see how to help those in need. Everyone is welcome. Information: 815-3555459. • 6 to 8 p.m. – How to Become a Family Child Care Provider training, Harvard Diggins Library, 900 E. McKinley St., Harvard. Offered by 4-C: Community Coordinated Child Care. Free. Registration and information: 815-344-5510, ext. 12. • 7 p.m. – Lifetree Café, Conscious Cup Coffee, 5005 Northwest Highway, Crystal Lake. Discussion topic will be about personal histories. Free. Information: 815-715-5476. • 7 p.m. – Powder Dogs Ski and Snowboard Club meeting, Nick’s Pizza & Pub, 856 Pyott Road, Crystal Lake. Sign up meeting for trips to Granite Peak and Devilshead. Information: 847-854-4754 or. • 7 to 8 p.m. – “Jacqueline Kennedy: A One Woman Show,” Algonquin Area Public Library, 2600 Harnish Drive, Algonquin. Actress and historian, Leslie Goddard, returns as the former First Lady. Free. Registration and information: 847-458-6060 or. • 7:30 to 9 p.m. – McHenry County Civil War Round Table meeting, Woodstock Public Library, 414 W. Judd St., Woodstock. Don Purn will speak on “Lincoln’s McHenry County Soldiers.” All are welcome and encouraged to attend. Information:.
Nov. 12-16 • 10 a.m. to 3 p.m. – Little Christopher Resale Shoppe, 469 Lake St., Crystal Lake. Offering clothing, housewares, books, toys, jewelry and more. Hours are 10 a.m. to 3 p.m. Tuesday through Friday, 10 a.m. to 1 p.m Saturday. Sponsored by the Women’s Club of St. Thomas the Apostle Church to benefit the church. Information: 815-459-9442. • 10 a.m. to 4 p.m. – Heavenly Attic Resale Shop, 307 S. Main
St., Algonquin. Offering books, clothing, housewares, toys, linens, jewelry, sporting goods and more. Hours are 10 a.m. to 4 p.m. Tuesday through Friday, 10 a.m. to 2 p.m. Saturday. Sponsored by the Congregational Church of Algonquin to benefit those in need. Information: 847-854-4552.
Nov. 13 • Noon – Tiara Tea Society luncheon, Crumpet’s Tea Room & Restaurant, 221 W. Main St., Genoa. Order off the menu. Registration and information: 847-5158039 or 847-669-6515. • 12:30 p.m. – Countryside Garden Club meeting, 1815 Andover Lane, Crystal Lake. Floral designer, Walter Fedyshyn, will speak on “Table Scapes - Tables for Two to Twenty Guests” and will create five holiday table arrangements to be sold. Bring a nonperishable food item for the local food pantry. Information: 815-477-0854. • 5:30 to 7:30 p.m. – MCC Night, McHenry County College, 8900 Route 14, Crystal Lake. Open house for prospective adult students, high school juniors, seniors and their parents to see what the college has to offer. Information: 815-455-8670 or. edu/mccnight. • 7 p.m. – Free Magazines and Music Online class, Algonquin Area Public Library, 2600 Harnish Drive, Algonquin. Learn how to use Zinio and Freegal. Registration and information: 847-458-6060 or.
Nov. 14 • 7:30 to 8:45 a.m. – Crystal Clear Toastmasters meeting, Panera Bread, 6000 Northwest Highway, Crystal Lake. Information:. • 9 a.m. to noon – “Get Covered Illinois” presentation, Huntley Park District’s Senior Fair, 12015 Mill St., Huntley. Hosted by the McHenry County Department of Health. Counselors will be on hand. Information: 847-669-3180 or. See COMMUNITY, page 2
COMMUNITY SPOTLIGHT: HUNTLEY
3
• Saturday, November 9, 2013
NORTHWEST HERALD EDITOR Jason Schaumburg 815-526-4414 jschaumburg.
Neighbors | Northwest Herald / NWHerald.com
Neighborhood collects for food pantry
Pat Totman (left) of Sun City Huntley Neighborhood 14 and Lydia Locke of the Grafton Food Pantry are pictured with some of the many groceries Neighborhood 14 collected during its annual food drive.
• COMMUNITY Continued from page 2 • 7 p.m. – Fly Fishing Basics, Fox River Grove Memorial Library, 407 Lincoln Ave., Fox River Grove. Presented by Liz Jacobs. Free. Registration and information: 847-639-2274 or www. frgml.org. • 7 p.m. – Free Short Sales/ Foreclosure seminar, Brokercity, Inc., 601 W. Main St., West Dundee. By Crystal Lake attorney James Huls. Registration and information: 847-707-3940 or jean@brokercity.com. • 7 p.m. – Lifetree Café, The Pointe Outreach Center. 5650 Northwest Highway, Crystal Lake. Personal histories will be explored. Free. Information: 815459-5907. • 7 p.m. – McHenry County Audubon presentation, Nature Center, 330 N. Main St., Crystal Lake. Refreshments followed by
“Learning From the Past for a Sustainable Future: A Century of Memories and Lessons from the Passenger Pigeon” with Steve Sullivan of the Urban Ecology for the Chicago Academy of Sciences. Information: 815-356-1710. • 7 p.m. – Social Security seminar, Colonial Café, 5689 Northwest Highway, Crystal Lake. Tom Boehmke of TAB Financial Services will host a free workshop on how to maximize your benefits. Registration and information: 800-817-3286. • 7:30 p.m. – American Legion Post 171 meeting, Park Place, 406 W. Woodstock St., Crystal Lake. Information: erik.neider@gmail. com.
Nov. 15 • 6:30 to 8:30 p.m. – Dating in the Millennium, United Methodist Church of Fox River Grove, 400 Opatrny Drive, Fox River
Grove. Explore changes facing singles. Guest speaker will be Dr. Nausheen Din. Free. Registration and information: arttolivby@ gmail.com. • 7 p.m. – “5 Broken Cameras” screening, Ridgefield-Crystal Lake Presbyterian Church, 8505 Church St., Crystal Lake. Documentary film about Israel and Palestine. Information: 815-4591132. • 7 p.m. – McHenry bingo, VFW Post 4600, 3002 W. Route 120, McHenry. Player-friendly games and prizes. Food available. Proceeds benefit families battling pediatric cancer. Information: 815-385-4600 or. • 7 to 8:30 p.m. – Zumbathon Party for the Pantry, Huntley Park District Cosman Theater, 12015 Mill St., Huntley. Fundraiser for the Grafton Food Pantry hosted by Natalie Block with multiple instructors, prizes and raffles.
Cost: $5 in advance, $10 at the door. Registration and information: 847-669-3180 or www. huntleyparks.org. • 7 to 9 p.m. – Creating Moments of Joy support group meeting, Monarch Senior Care, 234 Main St., Woodstock. Presentation, discussion and support for family caregivers of a person with Alzheimer’s. Registration and information: 888-672-7060 or care@monarchseniorcare. com.
Nov. 15-16.
Northwest Herald / NWHerald.com • Saturday, November 9, 2013
| Neighbors
4
BIRTHDAY CLUB Kyleigh DeBuck Rebman Age: 2 Birth date: Oct. 28, 2011 Parents: Eric and Cortney Rebman McHenry
To submit news, visit NWHerald.com/neighbors/connect Jacob Hunter Age: 3 Birth date: Nov. 8, 2010 Parents: Christy and Mike Hunter Woodstock
Brandon Raadsen Age: 4 Birth date: Nov. 6, 2009 Parents: John and Traci Raadsen Crystal: NWHerald.com/forms/birthday EMAIL: neighbors@nwherald.com MAIL: Birthday Club, Northwest Herald, P.O. Box 250, Crystal Lake, IL 60039-0250
CRAFT SHOWS Nov. 9 BAZAAR, 10th annual, 9 a.m. to 2 p.m. Nov. 9, Shepherd of the Prairie Lutheran Church, 10805 Main St., Huntley. Offering many unique, handcrafted items made by members of the church. There also will be a Santa Secret Shop for children to shop. Visit the café and bakery sweet stop. Information: 847-669-9448. CRAFT/VENDOR FAIR, second annual, 9 a.m. to 3 p.m. Nov. 9, McHenry Middle School, 2120 W. Lincoln Road, McHenry. There will be more than 40 booths with a variety of items. Hosted by the
McHenry Elementary Education Foundation. McHenry High School football team will sell food and refreshments. Information: 815385-7210. FALL CRAFT FESTIVAL, 9 a.m. to 3 p.m. Nov. 9, The Fountains at Crystal Lake, 965 N. Brighton Circle West, Crystal Lake. Show features dozens of local crafters. A portion of proceeds will benefit Watermark for Kids nonprofit organization that helps underserved local kids thrive. Free. Information: 815-477-6582. HOLIDAY CRAFT & VENDOR SHOW, 9 a.m. to 3 p.m. Nov. 9, Community Center, 255 Briargate
Road, Cary. Shop for gifts, home decor and accessories and more from a variety of crafters and vendors. Hosted by the Cary Park District. Free admission. Information: 847-639-6100 or www. carypark.com. HOLIDAY HAPPENINGS CRAFT & VENDOR FAIR, ninth annual, 9 a.m. to 3 p.m. Nov. 9, First United Methodist Church, 3717 W. Main St., McHenry. A variety of crafters and home party vendors will be on hand. There will also be a bake sale, chili lunch and craft raffle. Proceeds will benefit church missions and charities. Information:
815-385-0931.
Nov. 17 GLOBAL GIFT SHOP, 8:30 a.m. to 12:30 p.m. Nov. 17, Ridge-
Nov. 23 CHRISTMAS IN THE COUNTRY CRAFT SHOW, 34th annual, 8 a.m. to 3 p.m. Nov. 23, St. Elizabeth Ann Seton Church, 1023 McHenry Ave., Crystal Lake. More than 60 juried craftsmen will offer a variety of baskets, sewn and wood items, jewelry, and more. Admission: $1. Information: 815-455-1233.
non-veterans. Information: 847669-2636. • 9 a.m. to 5 p.m. – Free haircuts for veterans and active duty military, Modern Wave Salon and Spa, 395 Cary-Algonquin Road, Cary. Offer also valid for police and fire personnel. Appointments and information: 847-516-9283. • 10 a.m. to 6 p.m. – Open house and Veterans Affairs burial benefits seminar, McHenry County Memorial Park, 11301 Lake Ave., Woodstock. Learn what the VA provides and does not provide. Veterans and their families are invited and encouraged to attend. Seminars scheduled every hour. Free. Registration and information: 815-338-1320. • 11 a.m. – Veterans Day cere-
mony,. Gifts and goodies will be passed out to thank veterans and service members for their service. Information: 815-338-3180 or. • 1 to 2 p.m. – Veterans Day celebration, Advocate Good Shepherd Hospital Lakeview Room, 450 W. Highway 22, Barrington. Honor Guard, Pledge of Allegiance, patriotic music, veteran slide show,
refreshments and opportunity to. Nov. 12 • 10:30 a.m. – Senior Services’ Veterans Day tribute, McHenry Township Recreation Center, 3519 N. Richmond Road, McHenry. Presentation by Andy Balafas, Veterans Community Liaison with Vitas Hospice Care, patriotic sing-a-long, cake and coffee. Free. Registration and information: 815-344-3555.
Nov. 9-10 HOLIDAY BAZAAR & CRAFT SHOW, 9 a.m. to 5:30 p.m. Nov. 9 and 8 a.m. to 1 p.m. Nov. 10, St. John the Baptist Parish Hall, 2302 W. Church St., Johnsburg. Featuring more than 50 craft tables, religious articles, bake sale and light-lunch café. Sponsored by Blessed Virgin Mary Sodality. Free. Information: 815-385-1477.
field-Crystal Lake Presbyterian Church, 8505 Church St., Crystal Lake. Featuring fair-trade goods including clothing, chocolates, coffee, olive oil and gift items. Information: 815-459-1132.
VETERANS DAY EVENTS Nov. 10 • 1 to 2 p.m. – Screening of “Homes for Heroes,” McHenry Public Library, 809 N. Front St., McHenry. Film, narrated by Ron Magers, describes the experience of veterans who have benefited from Transitional Living Services Veterans of McHenry. Information: 815-385-0036 or. Nov. 11 • 9 a.m. – Breakfast and Veterans Day recognition program, Marlowe Middle School, 9625 Haligus Road, Lake in the Hills. All District 158 area veterans and spouses invited to attend. Hosted by the staff and students at Marlowe Middle School. Registration and
information: 847-659-47
5
Algonquin
Cary
Book club to meet Wednesday at church The Cary Area Book Club will meet 12:30 p.m. Wednesday at St. Paul’s United Church of Christ, 458 Woodstock St., Crystal Lake. Betsy Means of Women’s
Lore will present “Daisy’s Girls, Camping with Juliette Low.” Guests and new members are welcome. For information, call 847-639-9006.
Algonquin
Entries accepted for fall photo contest
Crystal Lake
Clair will host a photography class 7 to 9 p.m. Thursday at the Lake in the Hills Village Hall, 600 Harvest Gate. The fee is $54 for residents and $64 for nonresidents. For information, visit or call Katie Gock, recreation coordinator, at 847-658-2700.
Stade’s Farm Market
will be open until Wednesday, Nov. 27th Fall produce, including squash, potatoes, onions, apples, carrots & more! New line of Quilted items, baskets, and more for Christmas gifts! Apple Cider Donuts available on Farm Fresh Saturdays and Sundays only! Apple Cider
Available Holiday Pies & Breads for Thanksgiving - Please order by:
November 11th
SERVICE PROJECT – American Heritage Girls, a faith-based character development program, celebrated National Day of Service by donating bags of items to CASA of McHenry County. Pictured (top row, from left) are Sarah Breslin, Krista Piwonka, Tammy Kohls, Karoline Reiter, Ashley Butts, Victoria Tucker, Katherine Breslin, Samantha Tucker, Kate Krallitsch, Lisa Reiter, Michelle Johnson and Monica Venne; (middle row) Paige DiCecco, Abby Grant, Hailey Piwonka, Payton Winnicki, Molly Hartigan, Morgan Piwonka, Sophie Nieckula and Samantha Beckert; and (front row) Erin Johnson, Faith Venne, Anya Osoria, Kerri Johnson, Michaela Johnson, Colleen Dunlea, Trinity Kohls, Elizabeth Giangrego, Kailie Rosato, Addison Krallitsch and Kacie Krallitsch.
• Saturday, November 9, 2013
FESTIVAL PERFORMANCE – Members of The McDance Company from The Rebecca McCarthy School of Dance in Algonquin performed at the School District 300 Multicultural Festival at Spring Hill Mall. Pictured (front row, from left) are Natalie Dick, Ainslie Hoelter, Keira Ogden and Ainsley Bryson; (second row) Hannah Sullivan, Lanie Riese, Olivia Varkados, Aliyah Ogden and Madeline Hoeppner; and (third row) Krista Quinn, Tarryn O’Rourke, Sarah Glass, Kendall Douglas, Nicole Navarro, Lauren Dick, Kendall Kardys and Courtney Ramsey.
The Algonquin Recreation Division is accepting entries for its fall photo contest through Dec. 2. Your photo may be used on the village of Algonquin’s website or found in the recreation guide. Entries should be emailed to recreation@algonquin.org. Photographer George Le-
Neighbors | Northwest Herald / NWHerald.com
Communities listed alphabetically • To submit news, visit NWHerald.com/neighbors/connect
COMMUNITY NEWS
To submit news, visit NWHerald.com/neighbors/connect
Crystal Lake
Crystal Lake
Teachers group to host Beethoven program The Fox Hills Music Teachers Association will meet 9:30 a.m. Monday at First Congregational Church, 461 Pierson St. Following the meeting, Julian Dawson will present
Northwest Herald / NWHerald.com • Saturday, November 9, 2013
| Neighbors
6
the program “Beethoven: His Sonatas and Smaller Pieces in a Pianist’s Life Today.” For more information, visit or call Renae Schlossmann at 847-515-7905.
Crystal Lake
Garden club to host guest speaker
COMEDY FUNDRAISER – Joe Cicero (left) and Tina Bree from Star 105.5 perform at the Listening Room at Lakeside Legacy Arts Park during a comedy show to raise money for the Care4 Breast Cancer 5K.
Countryside Garden Club will host “Table Scapes – Tables for Two to Twenty Guests” 12:30 p.m. Wednesday at 1815 Andover Lane. The guest speaker will be Walter Fedyshyn, an International Design School instructor and floral designer of the year. He has designed for two Presidential Inaugurations, FTD National Conventions, art museums and the Academy Awards. Fedyshyn is the creative design manager for Phillips Flowers in Chicago. He will create five holiday table arrangements using articles
found in one’s home and will demonstrate how to build tabletop displays to fit any size dinner gathering. Ordinary kitchen and dining room accessories will be combined to add dimension to dinner party decor and centerpieces from petite to full size. All arrangements will be sold at the conclusion of the program. Everyone is encouraged to bring a nonperishable food item that will be donated to a local food pantry. For information, call 815477-0854.
Hebron
2616 Schaid Court/McHenry, IL 60051 • 815-385-1488 • TheTwistedMoose@gmail.com
Serving Northern Illinois for Over 40 Years!
Follow a greener path to a cleaner world!! We’ll pay you for your recyclable scrap metal..
COOKING BREAKFAST – The middle school Sunday school class at St. John’s Lutheran Church recently cooked breakfast for the congregation. Pictured (back row, from left) are Niki Morris, Maggie Morris, LuAnn Knoll, Brea Knoll, Emma Klein, Karly Strand, Katie Pedraza, Maddy Vole, Caitlyn Morris, Grace Rogers and Toby Behrens; and (front row) Austin Kastning, Noah Higgins and Justin Strand.
Closed 12:15 - 12:45 p.m. for lunch.
Our Service Makes a Difference!
To submit news, visit NWHerald.com/neighbors/connect
Huntley
Johnsburg
Crystal Lake
Learn how to use social media Nov. 20 The Aging Well Community Speakers Bureau will present a program on how to use social media 9:30 a.m. Nov. 20 at the Algonquin Township Office, 3702 Route 14. The free educational seminar will be given by
Judy West and Mary Kay Lauderback of JMK Simple Solutions. Coffee and snacks will be served. Those attending should RSVP by calling 847-462-0885 or emailing lecia.szuberla@ elderwerks.com.
Marengo
4113 W. Shamrock Lane | McHenry, IL 60050
(815) 344-0220 50% OFF GIFT CERTIFICATES Limited quantities available at “Great place to be!” w w w. t h e v i l l a g e s q u i r e. c o m
McHENRY • 815-385-0900 • Rt. 120 CRYSTAL LAKE • 815-455-4130 • Rt. 14 SOUTH ELGIN • 847-931-0400 • 480 Randall Road WEST DUNDEE • 847-428-4483 • 125 Washington Street
KOOL KID – Maddy Fitch was named the Kool Kid of the Month at Prairie Community Bank.
• Saturday, November 9, 2013
SCHOOL REPRESENTATIVE – Johnsburg High School sophomore Emily Crow was selected by the school’s faculty as this year’s representative for the Hugh O’Brien Youth Foundation State Leadership Seminar. She is the daughter of Trina Crow of Johnsburg and Michael Crow of Crystal Lake.
BLOOD DONORS – Sir Knight Phil Miller talks with his wife, Charlotte, while she donates blood at the recent blood drive sponsored by the St. Mary of Huntley Knights of Columbus Council 11666. The next blood drive will be Dec. 7 at St. Mary Catholic Church in Huntley.
7
Neighbors | Northwest Herald / NWHerald.com
COMMUNITY NEWS
Northwest Herald / NWHerald.com • Saturday, November 9, 2013
| Neighbors
8
COMMUNITY NEWS
To submit news, visit NWHerald.com/neighbors/connect
Johnsburg
Johnsburg
Distinguished graduate nominations needed Johnsburg High School is seeking nominations for the Distinguished Graduates Program. To be eligible, a Johnsburg High School graduate must be 28 years of age and
have distinguished themselves after their formal education. Nominations will be accepted through Feb. 1. For nomination forms, email Rose Rayner at rrayner@johnsburg12.org.
Garden Prairie
Church to serve turkey supper
STUDENTS OF THE MONTH – Alex Garcia (left) and Annika Burmeister were named the fifth-grade students of the month at Johnsburg Junior High School.
Johnsburg
Garden Prairie United Church of Christ will host a turkey supper 4 to 7 p.m. Nov. 16 at 10990 Route 20. The event also will include a craft sale and baked items sold by Sunday school
students. Tickets are $9 for adults, $4 for ages 6 to 12 and free for ages 5 and younger. Carryouts will be available. For information, call Ruth Ross at 815-597-4421.
Crystal Lake
Seminar to talk about Social Security benefits Tom Boehmke of TAB Financial Services will host free workshops on how to maximize Social Security benefits 10 a.m. today at Crystal Lake Public Library, 126 Paddock St., and 7 p.m.Thursday at Colonial Cafe, 5689 Route 14. Boehmke will cover how
to decide the best time to apply, how much income you can expect to receive, how to minimize taxes, how to coordinate benefits with your spouse and how working can affect your benefits. For reservations, call 800-817-3286.
Fine Dining at Reasonable Prices
Chef Davito’s STUDENTS OF THE MONTH – Hannah Diedrich (left) and Simon Stried were named the sixth-grade students of the month at Johnsburg Junior High School.
Johnsburg
Steakhouse and Italian Restaurant
Open Tues. - Thurs. 3-9 p.m. , Fri.-Sat. 3-10 p.m., and Sun. 3-8 p.m.
4000 N. Johnsburg Rd., Johnsburg, IL 60051
JUST CALL 815-363-8300
3018 N. Hickory Dr. McHenry, IL 60050 (815) 344-3455
Read all about it ...
Sunday STUDENTS OF THE MONTH – Rachel Dworshak (left) and Joseph Romano were named the seventh-grade students of the month at Johnsburg Junior High School.
Fashion, home decorating, gardening, announcements and more!
To submit news, visit NWHerald.com/neighbors/connect
Johnsburg
Johnsburg
Pasta dinner to raise money for veterans trip The Veterans Fundraiser Pasta Dinner will be 5 to 9 p.m. Nov. 16 at the McHenry Moose Lodge, 3535 N. Richmond Road. Profits from the dinner will be used to help send military veterans to tour Washington D.C. There will be raffles, a
silent auction, live music and more. Admission is $8 for adults and $6 for veterans, activeduty military and ages 12 and younger. For information, visit, or call 815-236-2029 or 847740-0541.
Katie Van Diggelen Owner
PRONATION Pronation is an inward tilt rotation of the hind and midfoot with a lifting of the outside border of the midfoot and an outward swing of the forefoot. Pronation is generally observed in the pes planus foot.
STUDENTS OF THE MONTH – Dylan Paprocki (left) and Hailee Gerner were named the eighth-grade students of the month at Johnsburg Junior High School.
2 Shoe Stores - 1 Convenient Location 1 Crystal Lake Plaza - Crystal Lake, IL 60014
815.444.7239
Johnsburg
815.444.8170 CRYSTAL LAKE
A+ Dog Training Successfully training McHenry County dogs for over 20 years!
815-337-5907
This is SUCCESS! This coupon worth $25.00
OFF
ANY GROUP CLASS New Clients Only - Limit 1 Per Customer. No Cash Value
CLASSES OFFERED:
Puppy Kindergarten, Obedience, Rally, Conformation, Agility & Behavior Modification STUDENTS OF THE MONTH – Leah Kottke (left) and Jack Folz were named the exploratory students of the month at Johnsburg Junior High School.
• Saturday, November 9, 2013
The Right Pair of Shoes Can Make All the Difference
9
Neighbors | Northwest Herald / NWHerald.com
COMMUNITY NEWS
Northwest Herald / NWHerald.com • Saturday, November 9, 2013
| Neighbors
10
COMMUNITY NEWS
To submit news, visit NWHerald.com/neighbors/connect
McHenry
Johnsburg
Square dance club announces next event The McHenry B&B Square Dance Club will be dancing 7:30 p.m. Friday at the Johnsburg Community Club, 2315 W. Church St.
The theme will be “Gobble Fest.” Attendees are asked to wear square dance attire. For information, email haklib@yahoo.com.
McHenry
Ladies auxiliary to host brunch Sunday The Polish Legion of Americans Veterans Post 188 Ladies Auxiliary will host a brunch 10 a.m. to 1 p.m. Sunday at the post, 1304 Park St. Suggested donations for
the all-you-can-eat buffet are $7 for adults and $3 for ages 9 and younger. Proceeds will help hospitalized military veterans. For information, call 815385-9789.
Lake in the Hills
Bus trips available for seniors this month
TROOPS SUPPORT – Brake Parts Inc. and its employees recently donated $5,807.75 to the Ladies VFW Auxiliary of McHenry, who is working with the Auxiliary of the McHenry PLAVA. This money will go to their Care Package Program which regularly sends more than 100 care packages every three months to U.S. soldiers overseas. Pictured (from left) are Lucille Pries, Barbara Klapperich, Lisa Victory, Candy Ostrum, Tim Boswell, Ruthanne Ozark-Kuss, Kay Plantan and Patricia Baur.
McHenry
The Lake in the Hills Parks and Recreation Department is hosting two bus trips for seniors this month. There will be a trip Nov. 18 to Hollywood Casino in Joliet. The cost is $7 for residents and $9 for nonresidents, and includes transportation.
There also will be a trip to see “Hello, Dolly!” Nov. 21 at Drury Lane Theatre in Oakbrook Terrace. The cost is $55 for residents and $60 for nonresidents. The cost includes transportation, lunch and the show. For information, call 847-960-7460.
Plum Garden Since 1965 3917 W Main Street McHenry, IL 60050 P: (815) 385-1530 F: (815) 385-1330
4005 Main St in McHenry 815-385-4110
UP TO 50% OFF GIFT CERTIFICATES Limited quantities available at
BLOOD DRIVE – The National Honor Society from McHenry High School East campus sponsored a blood drive. During the event, 98 pints of blood were collected. Pictured (back row, from left) are Casey Buenzli, Ashley Moore, Jacqueline Arevalo and Samantha Fett; and (front row) Kerrigan Schmidt and Caroline Monsen.
No-kill, cageless, non-proit shelter for dogs and cats.
815-455-9411 • info@assisi.org
To submit news, visit NWHerald.com/neighbors/connect
McHenry
McHenry
McHenry
McHenry
Church to honor veterans during Mass The Church of Holy Apostles will honor all military veterans and current military members and their families during a special Mass 6:30 p.m. Tuesday at 5211 W. Bull
Valley Road. A reception sponsored by the Catholic Order of Foresters will follow Mass in the narthex. For information, call the parish office at 815-385-5673.
“Come for the Food, Stay for the Entertainment”
1402 N Riverside Dr. McHenry, IL 60050
815-578-8360
Every Friday and Saturday RSVP Recommended!
Nicolino’s HOMECOMING COURT – Among those pictured are McHenry West High School homecoming court members Jessica Holzer, Cole Petty, Katarina Purich, Joseph Petrow, Hailey Strzalka, Justin Saenz, Cecelia Lentz, Luke Nelson, Kailey Bianchi, Luke Krauser, Chloe Fischer, Justin Johnson, Gracie Holmes, Colin Condon, Samantha Levin and Nicolas Almazan.
Spor ts, Spirits & Eater y 621 Ridgeview Drive • McHenry • (815) 344-9800
• Saturday, November 9, 2013
MEETING GUEST – The Rotary Club of McHenry welcomed Kim Larson to its regular meeting. She is the executive director of Family Alliance, a local agency for aging assistance that just celebrated its 30th anniversary.
ANNUAL VOLLEY FOR A CURE – McHenry High School had its second annual Volley for a Cure tournament. Pictured are the winning West campus teachers and students (back row, from left) Nick Higgin, Greg Johnson, Jeff Brunstrum, Kyle Owens, Dennis Hutchinson and Rob Neimic; and (front row) Kerrigan Schmidt, Evan Hying, Rachel Ford, Anna Synder and coach Kim Miller.
11
Neighbors | Northwest Herald / NWHerald.com
COMMUNITY NEWS
Northwest Herald / NWHerald.com • Saturday, November 9, 2013
| Neighbors
12
COMMUNITY NEWS
To submit news, visit NWHerald.com/neighbors/connect
Richmond
Richmond
Crafters, vendors needed for benefit show Crafters and vendors are needed for a show to help the Johnsburg High School freshmen class raise money for its senior prom 10 a.m. to 4 p.m. Nov. 16 at the Highlands
of Kensington Manor, 8400 Cunat Blvd. Table prices for crafters and vendors are $50. For information, email denisejordan@yahoo.com or call 815-546-3198.
Ringwood
Learn about study of area wildlife Nov. 16 McHenry County Conservation District will present of panel of regional animal experts who will talk about a study of coyotes, sandhill cranes, feral cats and green snakes 1 to 4 p.m. Nov. 16 at Lost Valley Visitor Center in Glacial Park, Route 31 and Harts Road. Results of these studies
also may help to direct future natural resource management decisions. The program is for ages 14 and older. Admission is free for McHenry County residents and $6 for nonresidents. Registration deadline is Monday. To register, call 815-479-5779.
Thinning Hair Solutions Woman’s Thinning Hair • Men’s Hair Replacement Specializing in Alopecia Before
VOLUNTEER AWARDED – Main Stay Therapeutic Riding Program volunteer Jean O’Brien was named the 2013 Volunteer of Year for the Professional Association of Therapeutic Horsemanship International’s Region 7. She is pictured with Cassa, a Main Stay therapy horse. ALTERNATIVES IN HAIR LOSS
Licensed Cosmetologist
665 Ridgeview Dr. • McHenry
McHenry
After
815-759-0329
3812 N. RICHMOND RD., RT.31) • MCHENRY, IL
(815) 385-4069 •
Super Stock Sale
We Beat The Competition
3witrhoopmresminiusmtallpeadd 647
$ for SKILLS TESTED – McHenry East High School students applied their trigonometry knowledge to find the heights of the kites they are flying. Pictured (from left) are Logan Peterson, Morgan Rudd, Brendan Wasmund and Alysia Fallon.
00 up to 40 yds.
HURRY! Sale valid 11/7/13 - 11/18/13
OPEN: MON-THURS 9AM-6PM, FRI 9AM-5PM, SAT 9AM-4PM
To submit news, visit NWHerald.com/neighbors/connect
McHenry
Spring Grove
Pet nail clipping to act as fundraiser Nature’s Feed will host a pet nail clipping with Fur the Love of Dogs 11 a.m. to 2 p.m. Nov. 16 at 2440 Westward Dr. Donations are requested.
All donations will benefit Spring Grove Food Pantry. For information, visit naturesfeed.net/events/ natures-feed-events or call 815-675-2008.
Wonder Lake
Food pantry to have open house Tuesday The Wonder Lake Neighbors Food Pantry will have an open house 6 to 7 p.m. Tuesday in the lower level of Nativity Lutheran Church, 3506 E. Wonder Lake Road.
Visitors wil learn about the operation, tour the stockroom and meet the volunteers and staff. For information, call 815575-2255.
Groups partner to collect for local pantry
QUILTING FOR WORLD RELIEF – Quilters from Zion Lutheran Church made quilts for “Quilting for Lutheran World Relief” that are sent to people in need. Pictured (from left) are Delores Glawe, Maria Bremer, Jean Grandt, Karin Kogerup
The annual the Wonder Lake Water Ski Show Team and Wonder Lake Master Property Owners Association’s annual Stuff the Ski Trailer Food Drive will be 9 a.m. to 1 p.m. today at various locations, Help the groups stuff the ski team trailer with nonperishable canned and boxed foods, paper products and personal care items.
Trailer will be at Wonder Lake State Bank, 7526 Hancock Drive. Monetary donation drop-off sites are Hancock and E. Wonder Lake roads, Thompson Road and Sunset Drive and at Wonder Foods, 7505 Hancock Drive. All donations will benefit the Wonder Lake Neighbors Food Pantry. For information, call 815814-4707.
Ringwood
VIDEO POKER HERE! FREE POOL! 1401 Riverside Dr., McHenry, IL
815-385-0012
TOWN CLUB
Restaurant & Sports Lounge 2314 W. Rt. 120 · McHenry, IL 60050
815-578-9400 fwgrill.com RIBBON LEADERS – Four leaders were chosen to represent Ringwood Primary Center at the Red Ribbon Kickoff at the Township. Among those pictured are Frank Silk, Lilia Duck, Joe Peshke and Ellyana Illg.
link to us on Facebook
• Saturday, November 9, 2013
Wonder Lake
13
NEIGHBORS | Northwest Herald / NWHerald.com
COMMUNITY NEWS
Northwest Herald / NWHerald.com • Saturday, November 9, 2013
| Neighbors
14
COMMUNITY NEWS
To submit news, visit NWHerald.com/neighbors/connect
West Dundee
Woodstock
TEACHERS GRANT– The Illinois Retired Teachers Association Foundation awards grant money to several public school educators. Pictured is Elon Shaffer (left) of Woodstock High School and Marti Swanson of IRTA. VOLUNTEERS OUTREACH – Saint James Episcopal Church parishioners volunteered at the Northern Illinois Food Bank in Geneva. They packaged 950 pounds of pasta to help provide 792 meals for those in need. Pictured (from left) are Mary Henning, Sevim Ablay, Mary Sams, Christine Dalphy, Greg Fuller, Lynn Zickefoose, Geoffrey Nobes, David Zickefoose, Father Don Frye, Wendy Werner and Debbie Wharton.
Union
Woodstock
Learn about school during annual open house Marian Central Catholic High School, 1001 McHenry Ave., will have its annual open house 1 p.m. Nov. 18. Elementary and junior high school students and their families are invited to
learn how a Marian Central Catholic High School education benefits students in all phases of their growth and development. For information, call 815338-4220, ext. 107.
Woodstock
Marian Central to have visit day Nov. 22 Eighth Grade Visit Day will be 9:45 a.m. to 12:45 p.m. Nov. 22 at Marian Central Catholic High School, 1001 McHenry Ave. In addition to eighthgraders from the Catholic elementary schools in
McHenry County, all eighthgrade students who currently attend public junior high and other private schools are encouraged to attend. For information, call 815338-4220, ext. 107.
CAMPUS REPORT
HISTORIC HALLOWEEN – Kathie Comella of Woodstock applies makeup to Diane Urban of Marengo in preparation for this year’s Historic Halloween at the McHenry County Historical Society Museum in Union.
MARQUETTE, Mich. – Thomas Daly of Cary received a bachelors degree in environmental studies from Northern Michigan University. • CHICAGO – Caelin Niehoff received the 2013 student Laureate of the Lincoln Academy from DePaul University. She is the daughter of David and Michelle Niehoff of Algonquin and a 2010 graduate of Marian Central Catholic High School in Woodstock. • PLATTEVILLE, Wis. – Kristina
Williams of Marengo received the Lulu Howery Scholarship from the University of Wisconsin-Platteville’s college of liberal arts and education. • AMES, Iowa – Local students received scholarships from the college of agriculture and life sciences at Iowa State University. Brandon Miller of Crystal Lake received the Jean Wallace Douglas Scholarship and Danielle Tucker of Marengo received the John Wesley Coles and Eda Coles Scholarship in Agriculture.
To submit news, visit NWHerald.com/neighbors/connect
Wonder Lake
Union
VOLUNTEER EDUCATES – McHenry County Historical Society volunteer Nancy Fike of McHenry educates attendees at the this year’s Trail of History in Glacial Park. Fike, retired society administrator, also delivered the keynote address at the historical society’s golden anniversary dinner at The Starline Factory in Harvard.
Private Kevin Kearley completed Marine Corps recruit training at MCRD San Diego, Calif., on Sept. 6. He has reported for additional Kevin Kearley training at Camp Pendleton, Calif. He is the son of Bill Kearley of Woodstock and a 2013 graduate of Marian Central Catholic High School. • Army Cadet Allison Holly graduated from the Army Reserve Officers’ Training Corps Leader’s Training Course at Fort Knox, Ky. Holly is a student at the University of Mary Hardin-Baylor in Belton, Texas. She is the daughter of Benjamin and Karen Holly of Crystal Lake and a 2010 graduate of Prairie Ridge High School. • Air Force Airman Frances Sumayop graduated from basic military training at Joint Base San Antonio-Lackland, San Antonio, Frances Texas. Sumayop Sumayop is the daughter of Dolores Sumayop of Crystal Lake. • Air Force Airman Adam R. Bolton graduated from basic military training at Joint Base San Antonio-Lackland, San Antonio, Adam Bolton Texas. He is the son of Robert and Leah Bolton of McHenry and a 2011 graduate of Wauconda High School. • Army Pfc. Trevor M. Hunter graduated from basic combat training at Fort Jackson, Columbia, S.C. He is the son of Kevin and
Bonnie Hunter of Cary and a 2011 graduate of Prairie Ridge High School. He earned an associate degree in 2012 from Le Cordon Bleu in Chicago. • Air Force Airman Sebastian T. Townsend graduated from basic military training at Joint Base San Antonio-Lackland, San Antonio, Texas. He is the son of Timothy Townsend of Lake Geneva, Wis., and a 2012 graduate of McHenry West High School. • Army Pvt. Riley J. Wilson graduated from basic combat training at Fort Jackson, Columbia, S.C. He is the son of Amy Nason of Crystal Lake and a 2012 graduate of Crystal Lake Central High School. • Air Force Airman Richard J. Marcantonio graduated from basic military training at Joint Base San Antonio-Lackland, San Antonio, Richard Texas. Marcantonio He is the son of Loretta and Richard Marcantonio Sr. of Lake in the Hills and a 2005 graduate of Marian Central Catholic High School in Woodstock. He received a bachelor’s degree in 2009 from Illinois State University in Normal. • Army Pfc. Nicholas C. Adams graduated from basic combat training at Fort Jackson, Columbia, S.C. Adams is the son of Adam and Lisa Adams of Huntley and a 2012 graduate of Huntley High School. • Private Nicholas Alexander Lanaski of Crystal Lake graduated from the United States Marine Corps boot camp at Marine Corps Recruit Depot in San Diego. He will report to Camp Pendleton for two months of Infantry Training Battalion then Military Occupation Specialty School.
• Saturday, November 9, 2013
AFTERNOON TEA – Nativity Lutheran Church recently had its fourth annual Afternoon Tea. Pictured (front row, from left) are Maddie Pepe of Project Linus and Wonder Lake Neighbors Food Pantry coordinator Kim Halper; and (back row) Nativity Lutheran Church members Jean Mickelsen, Arlene Gildemeister, the Rev. Susie Hill, Joann Wedin, Louise Cushley, Suzanne Aberle and Susan Claussen.
SERVICE REPORT
15
Neighbors | Northwest Herald / NWHerald.com
COMMUNITY NEWS
Rd.
Rd . D ra pe r
. Dr
N.
R rg sbu n h Jo
Irene Ct.
W. Church St.
HOURS:
Angelo is proud to announce our 2nd Location is Now Open!
WE ARE HERE TO SERVE YOU!
ek
Bull Valley Rd.
re
31
h Dr.
120
d.
rC
4000 N. Johnsburg Rd. Johnsburg, IL 815-344-5800
t. Elm S
Shilo
4400 Elm - Rte. 120 McHenry, IL 60050 815-385-1430
Ringwood
Sale Dates November 6th thru November 12th da
Northwest Herald / NWHerald.com • Saturday, November 9, 2013
“NEW” Winter Hours Mon.-Fri. 8 am- 8 pm; Sat. 8 am to 7 pm; Sun. 8 am-6 p YOU CAN’T AFFORD TO NOT SHOP AT ANGELO’S Ce
| Neighbors
16
Monday-Friday 8am-8pm; Saturday & Sunday 8am-7pm
HOURS: Monday-Friday 8am-8pm; Saturday & Sunday 8am-7pm VISIT OUR WEB SITE FOR OUR WEEKLY SPECIALS • angelosfreshmarket.com
SENIOR CITIZENS DISCOUNT - EVERY TUESDAY AND THURSDAY ARE SENIOR CITIZENS DAYS ALL SENIORS 65 YEARS AND OLDER WILL RECEIVE 5%
ANGELO’S DELI
PRODUCE
HAM
349
79
LB
SALAMI LB
SARA LEE HOMESTYLE
3 LB. BAG
LB
ANGUS PRIDE
ROAST BEEF
$
4
29
2
CHEDDAR CHEESE
$
1
LB
DOMESTIC
3
99
LB
BUTTERBALL “NEW” ARTISAN
TURKEY BREAST .................................lb $389 SCOTT PETERSON VEAL
BOLOGNA ..................................................lb $289 SCOTT PETERSON
OLD FASHIONED LOAF ............lb $289 HEALTHY ONE SMOKED
CHICKEN BREAST .............................lb $299 ECKRICH BROWN
TURKEY BREAST .................................lb $349 FRESH CHELLINO
RICOTTA .........................................................lb $249 FRESH
FETA CHEESE ............................................lb $399 HOMEMADE
CRAB SALAD ...........................................lb $399 HOMEMADE
PASTA SALAD ........................................lb $249 HOMEMADE
ANTI PASTA SALAD.......................lb
$
3
99
99
HELLMANN’S,
MAYONNAISE................................ 30 oz. jar $399
LB
PAN O GOLD
WHITE BREAD......................1 lb. loaf 79¢
3
49
CELTO RED WINE
VINEGAR ......................................... 16 oz. btl.
LB
CENTRELLA ELBOW
LB.
MACARONI...................................2 lb. pkg.
FRESH LEAN
GROUND CHUCK $
SOUP ............................................... 10.75 oz. can
2
29
59
LB
PORK CHOPS.........................................lb $169 PORK CHOPS.........................................lb
1
$
SINGLES .........................................12 oz. pkg. 2/$4
TYSON
CORNISH HENS ..............................22 oz. 2/$6 ABSOPURE SPRING WATER ......1/2 ltr./24 pk. btls. $299
DUTCH FARM ORIGINAL
ENGLISH MUFFINS............12 oz. pkg. 79¢
79
FRESH LEAN SEMI BONELESS
PORK CHOPS.........................................lb $229 FRESH LEAN THIN CUT BREAKFAST PORK CHOPS.........................................lb $219 FRESH LEAN BONE IN COUNTRY RIBS ....................................lb $169 U.S.D.A CHOICE BONELESS BEEF STEW .....................................................lb $349 U.S.D.A. CHOICE BEEF SHANK ...........................................lb $249
FROM OUR KITCHEN
SATURDAY AND SUNDAY ONLY ANGELO’S FAMOUS HOT & READY TO GO (PLEASE TRY TO PRE ORDER)
FULL SLAB BABY BACK RIBS ..... ONLY $799 3’ ANYWAY YOU LIKE IT AMERICAN OR
99¢
DUTCH FARM AMERICAN
FRESH LEAN SIRLOIN
FRESH LEAN VARIETY PACK
169
$
CHEESE................................................ 5 oz. tub 2/$4
CHICKEN LEG QUARTERS ¢
99¢
BELGIOIOSO
FRESH GOV. INSPECTED
EA.
CALIFORNIA RED SEEDLESS GRAPES .........................................................lb $149 FRESH EXPRESS AMERICAN HEARTS OF ROMAINE, ITALIAN AND RED LEAF MIX SALADS ..............5-12 oz. pkg. 2/$4 WASHINGTON GALA OR RED DELICIOUS APPLES ............................................................lb 99¢ ZUCCHINI OR YELLOW SQUASH ........................................................lb 59¢ FLORIDA JUICE ORANGES ........................................4 lb. bag $249 FLORIDA RED GRAPEFRUITS ........................................lb 49¢ CALIFORNIA SWEET NAVEL ORANGES ...................................................lb 99¢ BABY BELLA WHOLE OR SLICED MUSHROOMS .......................... 8 oz. pkg. 2/$4 GRAPE TOMATOES ........................................... pint 2/$3
CAMPBELL’S CHICKEN NOODLE
LB 3 LBS. OR MORE
TROPICAL
SWISS CHEESE
$
$
PINEAPPLES $ 49
399
BROWN & SERVES ......... 6.4 oz pkg., 79¢
BOSTON ROAST
1
LB
BANQUET LINKS OR PATTIES
U.S.D.A. CHOICE BONELESS
NORTHWEST BOSE OR RED
OLD TYME SHARP
COFFEE .............. Your choice - 26 oz and 33 oz. $599
269LB
6
$
CUCUMBERS 3/$
89
HILLS BROS. ORIGINAL AND HI YIELD
NEW YORK STRIP STEAK
FARM FRESH
HAM
CHEESE............................................8 oz. brick $129
U.S.D.A. CHOICE BONELESS
3
49
LB
VIRGINIA SMOKED
$
$
1
PEARS ¢
DUTCH FARM SELECT VARIETY
199LB RIBS
CLEMENTINE $ 99
389
BACON ..............................................1 lb. pkg. 2/$5
FRESH LEAN BABY BACK
SUGAR SWEET
TURKEY BREAST
$
$
LB
RUSSET
8 LB. BAG
HOME KITCHEN
PORK CHOPS
POTATOES $ 29
349
GROCERY
FRESH LEAN CENTER CUT
APPLES ¢
PRIMO PRE SLICED GENOA
$
FRESH MEATS
WASHINGTON EXTRA FANCY HONEY CRISP
KRAKUS IMPORTED
$
DISCOUNT ON ALL PURCHASES. Cash Transactions Only.
ITALIAN SUB ............ Please “Pre Order” $1499
FRESH FROZEN FISH GROUPER FILLETS.............................................. lb $599 PERCH FILLETS ..................................................... lb $349 SOLE FILLETS ........................................................ lb $399 SEAFOOD MIX .................................................1 lb pkg. $249 BAY SCALLOPS................................ 60/80 ct. 1 lb pkg. $599
LIQUOR MILLER BEER ........................... 24- 12 OZ. CANS $1399 COORS/COORS LT.............. 24- 12 OZ. CANS $1399 HAMM’S BEER ....................... 30- 12 OZ. CANS $1099 CORONA BEER ................................12 PK BTLS $1299 LENIE ....................................................12 PK BTLS $1199 BLUE MOON .....................................12 PK BTLS $1299 | https://issuu.com/shawmedia/docs/nwh-11-9-2013 | CC-MAIN-2017-09 | refinedweb | 57,901 | 67.04 |
hi, i'm trying to write a programme that reads two integers, and outputs the sum of all even numbers between that range e.g 10 14 = 36 (10+12+14)
here is what i have so far, but i have messed up the calculation somewhere, any help would be greatly appreciated, thankyou
Code java:
import java.util.Scanner; public class Rangefinder { public static void main(String[] args) { Scanner scan = new Scanner(System.in); int num1, num2, min, max, amt = 0; System.out.println("Please enter two integers: "); num1 = scan.nextInt(); num2 = scan.nextInt(); min = Math.min(num1, num2); max = Math.max(num1, num2); for (int x = min; x <= max; x++) { amt = amt + x; } System.out.println(amt); } } | http://www.javaprogrammingforums.com/%20whats-wrong-my-code/7192-help-my-range-finder-programme-printingthethread.html | CC-MAIN-2016-26 | refinedweb | 118 | 68.97 |
JavaOne 2016 – Nucleus
JavaOne 2016 is over! For two weeks already, so maybe I’m a little late with this write-up. Well, it simply took some time to watch enough talks to get an impression of what was going on. But even two weeks are not enough – Oracle uploaded about a hundred videos from JavaOne 2016! So I had to pick a theme and I decided to stay close to the nucleus: the language and core libraries, standard and enterprise edition, themselves.
As tempting as they are, I abstained talks that strayed away from the motor of Java’s drive. So no, I didn’t even watch the talk about JUnit 5 – yet.
Java SE
Let’s start with the Java SE keynote. Honestly, I found neither the introduction nor the Mazda report particularly thrilling. But that’s just the first third of the 30 minute presentation.
It got more interesting when Mark Reinhold started to get technical. He talked about Java 9 in general (which I will do further below as well) and covered jShell and Project Jigsaw in particular. It got even more interesting when Brian Goetz joined him in an awkwardly choreographed entrance.
Imagine, we might be able to write this at some point in the future:
public class Point(int x, int y) { }
And the compiler generates fields, constructors, accessors, proper
equals,
hashCode, and
toString. Wow!
And it gets better! (Or worse, depending on how much you’re prefer clarity over succinctness.)
var url = new URL(""); var connection = url.openConnection();
As Brian makes very clear, this does not weaken Java’s type system. It just means that the compiler infers more types than it already does today.
Last but not least Brian quickly summarizes the projects Valhalla and Panama.
Before diving into the more focused talks, I want to recommend Ask the JDK Architects, where Mark Reinhold, John Rose, and Brian Goetz answered random questions regarding Java and the JVM. It’s a nice potpourri of why Java is the way it is and how that might change in the future.
Java 8
I found it interesting that there where a number of talks dedicated to Java 8 and that many of them where still presenting some of the basics. Others, and this made more sense to me, were more advanced and help developers, who mostly have been using it daily for a while now, to get the details right.
The first half of Stuart Marks’ Collections Refueled (slides) talk presented some extensions to the collections framework that happened in Java 8 and might’ve been overlooked due to the hype around streams. For example, I didn’t know about
Collection::removeIf,
List::replaceAll, or how
List::sort improved sort performance. He finished off with the
Comparator factories before turning to Java 9.
Another talk making sure you get everything out of Java 8 was Venkat Subramaniam’s A Few Hidden Treasures in Java 8, in which he covered varied topics like string joining, default methods, and parallel streams.
Talking about parallel streams, if you want to know more about how to create solutions that parallelize well, watch Stuart Marks’ and Brian Goetz’ Thinking in parallel. Here they gave succinct mental models for how to design good solutions and estimate parallel stream performance.
But let’s not get distracted from Venkat’s live coding marathon. In Let’s Get Lazy: Explore the Real Power of Streams he dived into laziness and why lazy evaluations are beneficial. He did it again in Refactoring to Functional Style with Java 8 – a journey from Java 8’s functional programming features to functional programming with Java 8. Why are higher-order functions, immutability, lambdas, streams, and laziness relevant and how do they come together?
I really enjoyed Journey’s End: Collection and Reduction in the Stream API, which took a deep dive into reduction and collectors. As I’ve written elsewhere, I’m not a fan of complex stream collection but that doesn’t mean it’s not good to know how to do it if you need to. Besides, Maurice Naftalin gave a lot of interesting background info as well.
Published by Hubble Heritage under CC-BY-SA 2.0
Java 9
Java 9 was of course a big topic and there were a lot of talks about it. Before heading into some of the details of the new version, though, I want to recommend two particular talks for those that have not yet spent a lot of time with Java 9.
The first, JDK 9 Language, Tooling, and Library Features by Joseph Darcy, gave a high-level overview over Java 9. Give or take, it was pretty much the spoken version of my ultimate guide to Java 9 (but it also covered some of the still unpublished second part).
Then there was Prepare for JDK 9 (slides), in which Alan Bateman explored what our projects should do to prepare for the new version. Some of the things he mentioned were which internal APIs Jigsaw is going make inaccessible and how to deal with that, the new run time’s file system layout, and the upcoming version string format. Finally he explained how the pretty cool multi-release JARs can help projects stay compatible to several versions.
Project Jigsaw
As all posts about Java 9 we have to talk about Project Jigsaw and the upcoming Java Platform Modularity System (JPMS). The Jigsaw team presented a series of talks where each built on the previous ones.
In Introduction to Modular Development (slides) Alan Bateman gave an introduction to the module system. He explained how modules are created and how the JVM handles them. Keywords were module declarations, readability, and accessibility; jlink is introduced as well.
Most of the next talk, Advanced Modular Development by Alex Buckley and Alan Bateman (slides), discussed how to migrate existing libraries and applications to the module system (largely via the unnamed module and automatic modules). The talk finished off with a continuation of jlink before ending in an extensive round of questions – some interesting, some less so.
A key ingredient in decoupling clients from implementations of an interface they depend on is a third party that detects implementations and makes them available to the client. This is often done by DI containers, which also inject the implementations. Another approach is the service locator pattern, where clients have to access a central registry to request implementations. Java already supports the latter with the
ServiceLocator class which, as Alex Buckley presented in Modules and Services (slides), has been extended to allow modules to easily publish and consume services.
Finally, in Project Jigsaw: Under the Hood (slides) Alex Buckley took viewers to the next level. He explained:
- the interaction of the module system and class loaders as well as the concept of layers
- how dependencies can be made transitive (
requires transitive)
- the current state of the face-off between encapsulation and reflection (
exports private)
- different kinds of modules (named, unnamed, automatic)
Unless you’ve been following Jigsaw very closely, you will learn a lot of new things here. Highly recommended!
If you still can’t get enough, watch the Project Jigsaw Hack Session with Alan Bateman, Mandy Chung, and Mark Reinhold.
APIs
I was a little surprised to find only two talks about the new APIs that Java 9 brings to the game, both given by Stuart Marks – maybe I just overlooked others?
The first one was in fact held by Stuart’s alter ego, Dr. Deprecator himself. In Enhanced Deprecation (slides) the doctor went into the details behind Java’s deprecation history and lifecycle, the additions to
@Deprecated coming in Java 9, new tooling (jdeprscan), and future deprecation work.
I already mentioned the other, Collections Refueled (slides), because it started off talking about Java 8. The second part began about half way through by explaining why there won’t be collection literals (short version: collections are part of the library, not the language, so language-level support would be awkward). Instead we get collection factory methods, which Stuart presented in-depth, including details like immutability, random iteration order, and more. In the last couple of minutes he laid out plans for the near and distant future.
Tooling
Build tools are probably the most interesting topic when it comes to Java 9 and Project Jigsaw. So how are they doing? In Java 9 and the Impact on Maven Projects Robert Scholte discussed all the things he had to do to make Maven work with Java 9. You should definitely watch this one if you’re using Maven! Interesting tidbits are the support for multi-release JARs, that the extra enforcer rule ban duplicate classes is a good way to detect split packages and, if you want to stay up to date, the Maven Wiki page for Java 9. An unfortunate detail is that there is currently no support for generating
module-info.java from
pom.xml, which leaves developers with the ugly chore to maintain dependencies in two places.
If you’ve ever seen Venkat Subramaniam code live, you’ll believe like I do that jShell, Java’s own and brand-new read-evaluate-print-loop (REPL for short), was made just for him. So in Interactive Development and Fast Feedback with Java 9 REPL he took it for a test drive. You’ll learn what a REPL is, what it’s good for, and how to use Java’s.
In Introduction to Troubleshooting in JDK 9 (slides) Yuji Kubota, Yasumasa Suenaga, and Shinji Takao explained the servicability tools jhsdb, jcmd, and the HeapStats agent, which were introduced or considerably improved in JDK 9. They present how to do things like configuring the JVM after it goes live, obtaining thread/heap dumps or class histograms, and detecting native memory leaks.
Java EE
First things first: Java EE 8 is scheduled for September 2017, version 9 just for one year later.
The vision for the Enterprise Edition is presented in the Java EE Keynote. In one word: cloud. In more words: cloud, microservices, cloud, hypewords, cloud. It is noteworthy that Anil Gaur went out of his way to stress that Oracle is listening (his emphasis, not mine) to its partners and customers. A couple of them were invited up on stage to support the Java EE roadmap. In the end, after an entry that was arguably even more awkward than Brian Goetz’s, there was even some code.
Java EE 8
If you’re interested in the state of the Java EE union and particularly the upcoming version 8, Linda DeMichiel’s Java EE 8 Update has you covered. She not only talks about 8, though, but also gives insight into focus areas and interesting proposals, for example for reactive programming, circuit breakers, and security. At last Linda lists other talks related to Java EE. Here are the non-cloud ones for which I could find a video:
-
- Configuration for Java EE 8 and the Cloud by Dmitry Kornilov
- Security for Java EE 8 and the Cloud by Kk Sriramadhesikan (slides only)
Moar Cloud
As we learned in the keynote, the cloud is important:
- Enterprise Java for the Cloud by Rajiv Mordani, Josh Dorr, and Dhiraj Mutreja
- Portable Cloud Applications With Java EE by Rajiv Mordani, Josh Dorr, and Joe Di Pol
- Java EE Applications on Oracle Java Cloud Service by Harshad Oak
- Migrate Java EE Applications to Microservices and Oracle Java Cloud by Tilen Faganel and Matjaz B. Juric
- Cloud Native Java EE by Mike Croft and Ondrej Mihalyi
Wonder how much these talks can possibly differ? So do I! (I didn’t watch them – not exactly a JEE guy.)
What Else?
This was the full front of Java SE and EE talks. But there were many more. Two particular topics that stood out were microservices and tooling. If you’re interested in those, take a look at the JavaOne 2016 playlist.
If you want to hear other peoples’ opinions of JavaOne, check out these posts:
- Groovy Podcast #33, Live from JavaOne 2016
- JavaOne 2016 Follow-Up by Josh Juneau
- Daily reports by Solita: day 1, day 2, day 3, executive summary (if you only read one, make it this one)
- More daily reports, this time by Canoo: day 1, day 2, day 3
- JavaOne 2016 Recap by FreeWave
- Oracle JavaOne 2016 by WhiteHorses
And unlike me, they were even there. :) | https://www.sitepoint.com/javaone-2016-nucleus/ | CC-MAIN-2019-30 | refinedweb | 2,064 | 59.23 |
First of all I'm sorry if this question has been asked before or if there is documentation about the topic but i didn't found anything.
I want to make a windows app that open windows file explorer and you can browse for and then select a mp3 file, so you can play it (and replay it) in this program. I know how to open file explorer, this is my code :
import java.awt.Desktop;
import java.io.File;
import java.io.IOException;
public class Main
{
public static void main(String[] args) throws IOException {
Desktop desktop = Desktop.getDesktop();
File dirToOpen = null;
try {
dirToOpen = new File("c:\\");
desktop.open(dirToOpen);
} catch (IllegalArgumentException iae) {
System.out.println("File Not Found");
}
}
}
I don't think you are approaching this right. You should use something like a FileDialog to choose a file:
FileDialog fd = new FileDialog(new JFrame()); fd.setVisible(true); File[] f = fd.getFiles(); if(f.length > 0){ System.out.println(fd.getFiles()[0].getAbsolutePath()); }
Since you are only getting 1 MP3 file, you only need the first index of the File array returned from the
getFiles() method. Since it is a modal dialog, the rest of your application will wait until after you choose a file. If you want to get multiple files at once, just loop through this aforementioned Files array.
See the documentation here: | https://codedump.io/share/WiHUzAhM2kQx/1/get-the-path-of-a-file-via-file-explorer | CC-MAIN-2017-26 | refinedweb | 225 | 67.45 |
The technique of building a standalone .NET executable when there is a mix of managed and unmanaged code has been first explained by Steve Teixeira
in,
which you are strongly recommended to read if this is new for you.
Our article uses that technique, but we will be building a 64-bit only program. The reason is that we are going to statically link compiled 64-bit
Assembly Language (or ASM) which is CPU dependent. You will have to take that into account when configuring the platform target on your .NET projects.
I developed two ASM routines that will be called from .NET. One performs a small Math calculation using SSE2 instructions. The other is a very fast encryption/decryption
routine using the XXTEA algorithm ().
The XXTEA alghorithm is a very strong encryption algorithm, but not to be used when the security
of a nation depends on it because a small number of people appear to know how to attack it. Anyway, we are not going to discuss cryptography here.
The routine that performs the Math calculation sin(val1^2 / val2) is shown below, just like this:
; Calculates sin(val1^2 / val2)
;double AsmMathCalc (double val1, LONGLONG val2);
AsmMathCalc proc FRAME val1:MMWORD, val2:SQWORD
mulsd xmm0, xmm0 ; val1^2
cvtsi2sd xmm1, rdx
divsd xmm0,xmm1
call sin
ret ; result is returned in xmm0
AsmMathCalc endp
The routine that performs the encryption/decryption is not shown here due to its length, you need to download it to see it. It opens the file
to be encrypted (or decrypted) and creates a file for the encrypted (decrypted) output. Then reads and encrypts (or decrypts) in chunks and writes
to the new file. Encrypted files are saved with the extension ".enc" added to the full file name, decrypted files add the extension ".dec".
Note that XXTEA works with 32-bit words; if the file length in bytes is not divisible by 4, we have to send more "4-filesize modulo 4" bytes to make up for the difference.
My approach was to create a Class Library C++ project. Then I placed the parts dealing with the managed code and unmanaged code in separate source code files.
Managed code:
// CInterop.h
#pragma once
#include "native.h"
using namespace System;
namespace CInterop {
//public ref class ASMCallingClass ; only for testing when compiling as library
ref class ASMCallingClass
{
public :
static double ASMMathCalc(double val1, LONGLONG val2)
{
return runAsmCalc(val1, val2);
}
static int ASMXXTea(LPWSTR fileName, LPDWORD Key, BOOL encode)
{
return runAsmXXTea(fileName, Key, encode);
}
};
}
Unmanaged code:
//native.cpp
#include "Stdafx.h"
extern "C"
{
double AsmMathCalc (double val1, LONGLONG val2);
int AsmXXTEAEncDec(LPWSTR val1, LPDWORD val2, BOOL val3);
}
double runAsmCalc(double val1, LONGLONG val2)
{
return AsmMathCalc(val1, val2);
}
int runAsmXXTea(LPWSTR fileName, LPDWORD Key, BOOL encode)
{
return AsmXXTEAEncDec(fileName, Key, encode);
}
Just for testing purposes, you can add the ASM compiled object file to Properties\Linker\INput\Additional Dependencies, but this will not be used in the final building
process because we will build all from the command line.
In this project, add a "using" clause for the C++/CLR namespace. If you have built the C++/CLR class library, you can test now if all is working.
If it does not, make the class ASMCallingClass public in the interop project and rebuild the library.
using
ASMCallingClass
You have three projects in total: the ASM project, the C++/CLR interop project, and the C# project.
To be able to build a single executable, you need to compile in dependency order. Native code first, second the interop code, and finally the 100% managed code.
Open a console window with the environment set for Visual Studio x64 compilations (in the Start menu, you may find Visual Studio x64 Win 64 Command Prompt, which is what we need).
<path>\jwasm -c -win64 -Zp8 asmrotines.asm
Note: There are a number of programs able to compile source code Assembly Language, they are called Assemblers. The most popular is MASM from Microsoft.
I have not used ML64 (64-bit MASM) though, because it does not support the "invoke" directive in 64-bit mode (and "invoke" speeds up the coding process
quite a bit) and a few other goodies we were used to in the 32-bit MASM. But JWasm is backward compatible with MASM (probably it is what MASM64 should have been),
which means that it is feasible to make this code compile under ML64 by suitably replacing the productivity enhancements like "invoke", "if else endif",
"user registers", and automatic frames.
You must test the ASM routines while you code them, because it is very easy to insert bugs in ASM. There are various ways of doing that.
For my demo program, I just linked the asmrotines.obj with a test program written in C, under Visual Studio. The reason is that the Visual Studio C++ IDE
has a built-in disassembler and you can single step the ASM instructions.
cl /c /MD native.cpp
The C/C++ compiler will generate the object file "native.obj".
cl /clr /LN /MD CInterop.cpp native.obj asmrotines.obj
The /clr switch generates mixed mode code, /LN creates a .netmodule, and /MD links with MSVCRT.LIB. Because this module contains a reference
to the native code, we also need to pass native.obj and asmrotines.obj so that this file can be passed through to the link line when the compiler invokes the linker to produce
the .netmodule. This is basically the explanation given by Mr. Steve Teixeira.
csc /target:module /unsafe /addmodule:cinterop.netmodule Program.cs
Form1.cs Form1.Designer.cs Properties\AssemblyInfo.cs
link /LTCG /CLRIMAGETYPE:IJW /ENTRY:Charp.Program.Main
/SUBSYSTEM:WINDOWS /ASSEMBLYMODULE:cinterop.netmodule /OUT:NetAndAsm.exe
cinterop.obj native.obj asmrotines.obj program.netmodule
And that's all about it!
Q: Any sample for mixing .NET and Assembly Language in a standalone 32-bit exe?
A: The same sample, but for 32-bit, is in my website at:.
CreateFileW
INVALID_HANDLE. | http://www.codeproject.com/Articles/266717/Mixing-Net-and-Assembly-Language-in-a-standalone-6?fid=1657745&df=90&mpp=10&sort=Position&spc=None&tid=4052702 | CC-MAIN-2016-18 | refinedweb | 990 | 63.29 |
0
Unable to open file with fstream. it always seems to jump to the else statement and gives me the error message "Error: can't open input file ". I have included in the header file
#include <iostream> #include <fstream> #include <sstream>
and in the class file i have the following code and yes i do have a txt file called studentFileName.txt in the same directory.
void StudentRecord::addFile(const string& studentFileName){ ifstream infile; infile.open ("studentFileName.txt"); if (infile.is_open()){ string line, word, StudentName, ProgramCode; while(getline(cin, line)){ istringstream stream(line); while (stream >> word) { int i = 0; if (i % 2 == 0) { StudentName = word; } else { ProgramCode = word; } StudentRecord::add(StudentName, ProgramCode); } } infile.close(); } else { cout << "Error: can't open input file " << endl; } }
Any solutions would be greatly appreciated as i am completely stumped.
Thankyou | https://www.daniweb.com/programming/software-development/threads/117712/unable-to-open-input-file-with-fstream | CC-MAIN-2017-30 | refinedweb | 135 | 56.15 |
Mount its RSA-2048 public key. The encrypted global key and the corresponding encrypted ChaCha20 key are appended at the end of each encrypted file.
This version includes a new worm feature that lets it self-propagate to other PCs on the network using IDirectorySearch and IWbemServices COM interfaces.
MountLocker has a sophisticated multithreading scheme, but its performance suffers from thread starvation due to recursive file traversal.
I won’t waste my time explaining why recursive file traversal is terrible anymore cause I have made my points through the last few reports. Please feel free to check out my Darkside analysis if you want to better understand the theory behind it!
Figure 1: XingLocker Ransomware leak site.
IOCS
This v5.0 sample is a 64-bit .exe file.
MD5: 3808f21e56dede99bc914d90aeabe47a
SHA256: 4a5ac3c6f8383cc33c795804ba5f7f5553c029bbb4a6d28f1e4d8fb5107902c1
Sample:
Figure 2: VirusTotal information.
Ransom Note
The ransom note is written in HTML format and is dropped into RecoveryManual.html files on the system.
The client ID embedded inside the ransom note is generated from the victim’s computer name and a hard-coded string in memory.
Figure 3: MountLocker ransom note.
Performance
MountLocker has pretty average performance and does not fully utitlize the machine’s processing power.
Figure 4: ANY.RUN sandbox result.
Static Code Analysis
Command Line Parameters
MountLocker can be ran with or without command line parameters. The ransomware first checks and parse the given parameters to modify its functionalities accordingly.
Figure 5: Parsing command line parameters.
Below is the list of arguments that can be supplied by the operators:
Logging
The ransomware has two different ways to log its operations, and each can be enabled through setting the command line arguments /CONSOLE to 1 and /NOLOG to 0.
In this particular sample, /NOLOG flag’s value is hard-coded to be 0, so it always records and drops a log file on the victim’s system.
When the /NOLOG flag is 0, MountLocker extracts the current executable’s file path, append .log to the end, and use that as the log file path.
Figure 6: Creating log file in current directory.
When the /CONSOLE flag is 1, MountLocker will also log through console standard output stream. It calls AllocConsole and GetStdHandle(STD_OUTPUT_HANDLE) to allocate the console and get a handle to the standard output stream.
To write to this console, it calls WriteConsoleW with this handle.
Figure 7: Creating log file in current directory.
The beginning of the log tells us the version of the specific MountLocker sample, and in this case, the version is 5.0.
It also extracts and records information about the victim’s system such as the number of processors, total system memory, Windows version, system architecture, …
Figure 8: Logging system information.
All file and network operations (enumeration, skipping, encrypting, error) are recorded this way.
Figure 9: MountLocker log file.
Terminating Services
If the /NETWORK argument is not provided, the malware will run in local mode.
In this mode, if the /NOKILL argument is 1, it enumerates and kills all services with these strings in their name.
"SQL", "database", "msexchange"
First, it calls OpenSCManagerA to obtain a handle to the service control manager and calls EnumServicesStatusA to enumerate all Win32 services with status SERVICE_ACTIVE.
Figure 10: Enumerating through all active services.
If a service contains any of the three strings above, MountLocker will terminate it by calling OpenServiceA to obtain a service control handle and calling ControlService to send a control stop code. It then continuously loops until the service’s state is SERVICE_CONTROL_STOP to make sure the service is fully terminated.
Figure 11: Sending control stop code to terminate service.
Terminating Processes
If it’s running in local mode and the /NOKILL argument is 1, MountLocker will enumerate and kill all processes with these strings in their name.
"msftesql.exe", "sqlagent.exe", "sqlbrowser.exe", "sqlwriter.exe", "oracle.exe", "ocssd.exe", "dbsnmp.exe", "synctime.exe", "agntsvc.exe", "isqlplussvc.exe", "xfssvccon.exe", "sqlservr.exe", "mydesktopservice.exe", "ocautoupds.exe", "encsvc.exe", "firefoxconfig.exe", "tbirdconfig.exe", "mydesktopqos", "sqlservr.exe", "thebat.exe", "steam.exe", "thebat64.exe", "thunderbird.exe", "visio.exe", "winword.exe", "wordpad.exe", "QBW32.exe", "QBW64.exe", "ipython.exe", "wpython.exe", "python.exe", "dumpcap.exe", "procmon.exe", "procmon64.exe", "procexp.exe", "procexp64.exe"
The ransomware first calls ZwQuerySystemInformation with the information class of SystemProcessInformation to get an array of SYSTEM_PROCESS_INFORMATION structures. It enumerates through each running process, avoids its own process, and starts terminating processes in the kill list.
Figure 12: Enumerating through all active processes.
To check and kill a process, it loops through the PROCESS_TO_KILL list and compares the process name. If the process name is in the list, it calls OpenProcess to get the handle of that process and terminates it using TerminateProcess.
Figure 13: Terminating processes that are in the kill list.
Generating Global ChaCha20 Key
Next, it randomly generates the global ChaCha20 key. The randomization is done through calling the rdtsc instruction to get the processor time stamp and xoring its least significant byte to generate each byte in the key.
After generating the global key, the ransomware copies the key to another global buffer in memory and encrypts this new buffer using the hard-coded RSA-2048 key.
Figure 14: Randomly generate global ChaCha20 key and encrypt it with RSA-2048.
MountLocker later uses this global ChaCha20 key to encrypt and protect its ChaCha20 keys instead of using RSA-2048. Since RSA-2048 encryption is only performed once, there is some performance advantage with this hybrid-cryptography scheme since RSA is quite slow compared to ChaCha20.
Encryption
Creating Encrypting Threads
Despite having different schemes for different drive types and targets, the encryption functionality is pretty much the same.
MountLocker has a specific function that takes in a drive/file name to encrypt and a function to enumerate through it as parameters.
This function first passes the enumerating function and the target name to a custom structure before spawning a thread to begin the encryption.
This thread acts as the main thread in the encryption, which recursively enumerates and provides files for children threads to encrypt.
Figure 15: Spawning main thread.
The main thread function calls CreateEventA to create an event handler for each child thread to later send them file information through calling SetEvent.
Only 2 children worker threads are spawned, and these threads loops and waits to receive files from the main thread to encrypt. The main thread will begin feeding them files by calling the enumeration function in the custom structure above and enumerating through the target folder.
Figure 16: Main thread spawning children threads and starting file enumeration.
Children Worker Threads
Once spawned, each worker thread receives a shared structure with the main thread, and it constantly loops to check for the encrypt signal is 1 in this shared structure.
Due to synchronization through sharing a common structure among threads, the child thread calls _InterlockedExchange to atomically extract the encrypt signal to check if it’s allowed to encrypt.
As it finds files to encrypt, the main thread adds the file name to the shared structure and sets the encrypt signal for the child thread to process that file.
Figure 17: Child thread waiting for encrypt signal to encrypt files.
After receiving the file information, the worker thread creates a structure to store file information such as filename, encrypted filename, file handle, file size, …
It will then checks to see if it has priviledge to open the file and retrieve the file size.
Figure 18: Checking if file can be opened.
Next, it randomly generates the file’s ChaCha20 key and appends it to the file structure above. The randomization is done through calling the rdtsc instruction similar to the global ChaCha20 key generation.
Figure 19: Randomly generating ChaCha20 key for each file.
After generating the ChaCha20 file key, the worker thread creates a 313-byte buffer that stores the file marker string “lock2” in little endian, the fast encryption size, the encrypted ChaCha20 global key, and the encrypted ChaCha20 file key. This buffer is appended at the end of the to-be-encrypted file.
Figure 20: Generating key buffer and writing it at the end of the file.
Here is the layout of the key buffer at the end of an encrypted file.
Figure 21: Key buffer layout.
File encryption is pretty standard. The worker thread encrypts a 0x100000-byte chunk at a time until it has encrypted FAST_CRYPT_SIZE bytes or ran out of bytes to encrypt.
It uses ReadFile to read file content into a buffer, encrypts it using the ChaCha20 file key, and writes it back using WriteFile. Because encryption is performed on the same file, SetFilePointerEx is called to adjust the file pointer after reading and writing.
Figure 22: ChaCha20 File Encryption.
I won’t analyze the ChaCha20 function cause MountLocker basically just uses this CRYPTOGAMS library by OpenSSL.
Main Thread Enumeration
MountLocker uses the same function for file traversal for network drives, network shares, and local drives.
Before traversing a drive, the ransomware checks if a marker file name is provided from the /MARKER= command line argument. If it is, MountLocker creates an empty file with this marker file name in the to-be-encrypted drive before enumerating it. This is mainly for marking which drive has been encrypted.
Figure 23: Creating drive marker file.
To enumerate through folders, MountLocker calls FindFirstFileW and FindNextFileW. When enumerating through network servers, it will use WNetOpenEnumW and WNetEnumResourceW instead.
Figure 24: Recursive file traversal.
The ransomware also calls a function to checks if it should encrypt each file/folder that it finds.
When processing a folder, the checking function will check for the following things. If any of these is true, the folder is skipped.
- If folder name is "." or ".." - If folder name is in the FOLDER_TO_AVOID list - If folder name is "Program Files", "Program Files (x86)", "ProgramData", or "SQL" - If calling CreateFileW on the folder fails. - If folder's reparse tag is not IO_REPARSE_TAG_MOUNT_POINT (folder is a mount point) or IO_REPARSE_TAG_SYMLINK (folder is a symbolic link)\ - If folder name is in a share name format - If folder is a mount point and is visible
Below is the FOLDER_TO_AVOID list.
":\\Windows\\", ":\\System Volume Information\\", ":\\$RECYCLE.BIN\\", ":\\SYSTEM.SAV", ":\\WINNT", ":\\$WINDOWS.~BT\\", ":\\Windows.old\\", ":\\PerfLog\\", ":\\Boot", ":\\ProgramData\\Microsoft\\", ":\\ProgramData\\Packages\\", "$\\Windows\\", "$\\System Volume Information\\", "$\\$RECYCLE.BIN\\", "$\\SYSTEM.SAV", "$\\WINNT", "$\\$WINDOWS.~BT\\", "$\\Windows.old\\", "$\\PerfLog\\", "$\\Boot", "$\\ProgramData\\Microsoft\\", "$\\ProgramData\\Packages\\", "\\WindowsApps\\", "\\Microsoft\\Windows\\", "\\Local\\Packages\\", "\\Windows Defender", "\\microsoft shared\\", "\\Google\\Chrome\\", "\\Mozilla Firefox\\", "\\Mozilla\\Firefox\\", "\\Internet Explorer\\", "\\MicrosoftEdge\\", "\\Tor Browser\\", "\\AppData\\Local\\Temp\\"
If the folder is valid and there is no ransom note file in the folder yet, MountLocker will drop a ransom note in the folder.
Figure 25: Dropping ransom note.
When processing a file, the checking function checks for the following things. If any of these is true, the file is skipped.
- If file size is less than MIN_CRYPT_SIZE (if MIN_CRYPT_SIZE is provided) or if file size is larger than MAX_CRYPT_SIZE (if MAX_CRYPT_SIZE is provided) - If file name is "RecoveryManual.html", "bootmgr", or has the encrypted file extension. - If file extension is in the EXTENSION_TO_AVOID list
Below is the EXTENSION_TO_AVOID list.
"exe", "dll", "sys", "msi", "mui", "inf", "cat", "bat", "cmd", "ps1", "vbs", "ttf", "fon", "lnk"
If the file is valid, the ransomware’s main thread will populate the shared file structure with the file name for its worker thread to encrypt.
Because of synchronization concerns, the main thread also has to call WaitForSingleObject and _InterlockedExchange to wait until it has access to the shared structure.
After populating the file structure, it calls SetEvent to signal the event for worker threads to encrypt.
Figure 26: Calling SetEvent to signal file encryption.
Worm Property
Similar to WannaCry and Ryuk, this MountLocker sample is a combination of ransomware and worm with the ability to self-propagate to other hosts in the network.
Unlike WannaCry, this ransomware does not use any fancy 0-day but instead just COM interfaces such as IDirectorySearch and IWbemServices to spread and execute itself.
MountLocker has this structure that is shared among all worm threads.
struct WORM_STRUCT { _QWORD function; // function to launch ransomware remotely _QWORD func_param; // function's parameter HANDLE hEvent; // worm event HANDLE hSemaphore; // worm semaphore };
First, memory is allocated for this structure, and the event handle and semaphore handle are created. The ransomware launching function and its parameter is originally left to be null initially.
MountLocker creates 8 threads to execute this worm property.
Figure 27: Populating worm struct and creating worm threads.
Each of these threads waits for the event to be signal by the main thread before calling the worm function to execute the ransomware remotely. The main thread will set this worm function accordingly before signalling the event.
Figure 28: Worm worker threads.
After creating these worker threads, the main thread begins enumerating the Windows domain that the current host is in.
This is accomplished through calling NetGetDCName to get the name of the primary domain controller and append this name after the string “LDAP://”.
Figure 29: Building LDAP path.
Lightweight Directory Access Protocol (LDAP) is a protocol to communicate and query several different types of directories, and in this case, MountLocker uses it to make Active Directory query requests to the primary domain controller.
It calls ADsOpenObject with the newly built ADsPath string and provides the credential (username and password) from the /LOGIN= and /PASSWORD= arguments. The RIID provided is {109BA8EC-92F0-11D0-A790-00C04FD8D5A8}, and through this call, the ransomware retrieves the IDirectorySearch interface.
This trick to query IDirectorySearch is previously used by Trickbot as explained by Vitali here.
Figure 30: Querying IDirectorySearch interface.
This interface can be used to execute a search for all domain controllers through its IDirectorySearch::ExecuteSearch function which return an ADs search handle.
MountLocker calls IDirectorySearch::GetFirstRow and IDirectorySearch::GetNextRow to enumerate through all the searches, passing each search into a function to extract its domain controller information.
Figure 31: Enumerating through ADs searches to extract domain controller information.
For each of these search handles, MountLocker then calls IDirectorySearch::GetColumn with the column name “name” to retrieve the corresponding ADS_SEARCH_COLUMN structure at this row.
This structure contains an array of ADSVALUE structures, and each of these structures contains a DN string of a directory service object in the Active Directory. This Distinguished Name (DN) string is basically a name to identify another PC in the network.
Figure 32: Extracting all DN string of other PCs in the network.
When a DN string of a PC is extracted, it’s passed into a function where the ransomware will use it as the function parameter in the WORM_STRUCT structure. The structure’s function is set to a specific function that drops and launches the sample remotely. SetEvent is called to execute this function after the WORM_STRUCT structure is fully populated.
Figure 33: Setting up WORM_STRUCT and signal the worm event.
Worm Dropping Function
First, the worm thread will try to establish a connection to the remote target PC by calling WNetAddConnection2W and provice the username and password from the /LOGIN= and /PASSWORD= arguments.
Figure 34: Establishing connection with remote PC.
Next, memory is allocated for a custom structure. I just call this WORM_REMOTE_STRUCT.
struct WORM_REMOTE_STRUCT { LPCWSTR rem_exe_path; // remote executable path CHAR *launch_exe_cmd; // command line to launch executable CHAR *PC_name; // remote PC name CHAR *elevated_PC_path; // Elevated PC path to launch executable DWORD API_result; // result value DWORD last_error; // last error value CHAR *exe_name; // executable name };
It then populates this structure. The executable name is a number retrieved from GetTickCount, and the path on the host to drop the ransomware is set to “C:\ProgramData”.
Figure 35: Populating WORM_REMOTE_STRUCT.
The drop_ransomware function checks if the DN string contains either of the share names with higher priviledge ”\ADMIN$“ and ”\IPC$“. If it does, then MountLocker uses that as the main path in the command to launch the executable. If it doesn’t, then it just uses the normal path.
The ransomware sample is set to be launched with the /NOLOG parameter and any arguments provided in the original /PARAMS= argument.
Finally, it drops the ransomware on the target PC by calling CopyFileW.
Figure 36: Dropping the ransomware on the target PC.
Not only does MountLocker drops the ransomware executable on the target PC but it also enumerates through the PC’s shared resources in the PC’s network by calling NetShareEnum. After finding the path to each shared resource, the ransomware calls drop_ransomware to drop the executable in the shared resource’s system.
Figure 37: Dropping the ransomware on the target PC’s shared resources.
Worm Launching Function
MountLocker has two different ways to launch the executable on the remote host.
If the /NETWORK argument provided is s, it launches the executable through a service.
First, this full cmd.exe command is built.
cmd.exe /c start "ransomware_path PARAMS_VALUE /NOLOG"
Then, the ransomware calls OpenSCManagerW to establish a connection to the service control manager on the target PC. Using this handle, it calls CreateServiceW with the command above as its lpBinaryPathName parameter to create a service handle and calls StartServiceW to launch it.
Figure 38: Launching ransomware on remote host using Service.
If the /NETWORK argument provided is w, it launches the executable through Windows Management Instrumentation (WMI).
First, MountLocker retrieves the IWbemServices interface. This is done by calling CoCreateInstance with the CLSID {4590F811-1D3A-11D0-891F-00AA004B2E24} to retrieve an IWbemLocator object.
Using this IWbemLocator object, it calls the IWbemLocator::ConnectServer to connect with the PC’s ROOT\CIMV2 namespace and obtain an IWbemServices object.
Figure 39: Connecting to ROOT\CIMV2 namespace through COM objects.
From here, MountLocker sets up an appropriate SEC_WINNT_AUTH_IDENTITY_A structure with the given username and password. It then calls CoSetProxyBlanket to set the authentication information for this IWbemServices object.
Figure 40: Setting the authentication information for the IWbemServices object.
Using this IWbemServices object, the ransomware calls the IWbemServices::GetObjectA function with the “Win32_Process” path to get IWbemClassObject object corresponding to Windows32 processes.
Next, using this “Win32_Process” object, it then calls the IWbemClassObject::GetMethod function with the “Create” method name to get an IWbemClassObject object corresponding to the method to create a process.
With this method object, it calls the IWbemClassObject::SpawnInstance to create a new instance of the class.
Figure 41: Retrieving the COM object to create a Windows32 process.
Since the Win32_Process::Create requires a valid value for the command line in-parameter to execute properly, MountLocker calls the IWbemClassObject::Put function to set the value of the command line to the launching command that it has built above.
Figure 42: Setting valid value for command line in-parameter.
Finally, it calls IWbemServices::ExecMethod to create a Win32 process running the “cmd.exe” command above. It also checks to see if the new process is created successfully or not by checking if the process’s ID is changed through calling IWbemClassObject::Get.
Figure 43: Launching ransomware remotely using Win32_Process::Create.
If any of these steps to drop and launch the executable fails, MountLocker just resorts to using WNetOpenEnumW and WNetEnumResourceW to enumerate through the victim’s network and drops the ransomware in a similar fashion.
Self-Deletion
If the /NODEL argument is set to 0, MountLocker will delete its own executable.
First, it creates a .bat file in the TEMP folder with a random name from GetTickCount.
It writes this command into this .bat file, which clears Read-only, System, and Hidden file attribute from the ransomware executable, forces deletes the executable quietly if it exists, and deletes the bat file.
attrib -s -r -h %1 :l del /F /Q %1 if exist %1 goto l del %0
Next, MountLocker builds the command line string to execute the .bat file with the executable path as the parameter and finally calls CreateProcessW to delete itself.
Figure 44: Self-deletion.
YARA rule
rule MountLocker5_0 { meta: description = "YARA rule for MountLocker v5.0" reference = "" author = "@cPeterr" tlp = "white" strings: $worm_str = "========== WORM ==========" wide $ransom_note_str = ".ReadManual.%0.8X" wide $version_str = "5.0" wide $chacha_str = "ChaCha20 for x86_64, CRYPTOGAMS by <appro@openssl.org>" $chacha_const = "expand 32-byte k" $lock_str = "[OK] locker.file > time=%0.3f size=%0.3f KB speed=%" wide $bat_str = "attrib -s -r -h %1" $IDirectorySearch_RIID = { EC A8 9B 10 F0 92 D0 11 A7 90 00 C0 4F D8 D5 A8 } condition: uint16(0) == 0x5a4d and all of them }
References | https://chuongdong.com/reverse%20engineering/2021/05/23/MountLockerRansomware/ | CC-MAIN-2021-25 | refinedweb | 3,380 | 54.83 |
My app uses two databases (separate files). To handle these databases I have created two Helper classes which extend SQLiteOpenHelper, one for each database.
I am now going to add a third database and wonder whether I need to create yet another Helper class (and if I used a 4th and a 5th database would I need even more Helper classes), or can I use the same Helper class for multiple databases?
The problem that I see with trying to use just one Helper class is that I can't see how to pass the name of the individual database files to the Helper. At present the name of the database is hard-coded as a Static field of each of the Helper classes, but if I had only one Helper class I would need to be able to pass the different names in to the Constructor when creating the separate Helper objects; the problem is that the SQLiteOpenHelper Constructor seems to be called by Android with just one parameter: the Context.
Of course, you can. It is just a matter of your Helper class design. You can just pass the name of DB to your Helper class constructor (along with required
Context instance) instead of hardcoding:
public class DBOpenHelper extends SQLiteOpenHelper { public DBOpenHelper(Context context, String dbName, int dbVersion) { super(context, dbName, null, dbVersion); } ... } | https://codedump.io/share/dm4Le0crzJYc/1/android-can-i-use-one-sqliteopenhelper-class-for-multiple-database-files | CC-MAIN-2017-09 | refinedweb | 225 | 60.38 |
Using CORS with Restify in NodeJS
No ads, no tracking, and no data collection. Enjoy this article? Buy us a ☕.
Restify is Express without the cruft of a full-fledged back-end framework, and it provides a valuable way to prototype web services to get things up-and-running quickly. It also provides a solid number of plugins to enhance back-end capabilities, such as easily parsing body and query string fields into variables.
With Restify, you might want to stand up an API, but then check on that API via a single page application. These applications could each exist in testing on a different URL or port. For example, you could be running Restify on port 3000, but have a single page application consuming the web services via port 8080, or some IIS Express port. If you attempt to connect to your API endpoint via JavaScript in the single page application, you're likely to see an error somewhat to the effect of:
Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at (Reason: CORS header 'Access-Control-Allow-Origin' missing).
Even if you're client application is set up to enable CORS, your server application needs to be configured as well. Restify--at one time--included this out-of-the-box--available via
restify.CORS(), but that's no longer the case. Now you must include a third-party middleware component.
To install:
npm install restify-cors-middleware --save
For TypeScript users, you can get the typings via DefinitelyTyped using the NPM scope:
npm install @types/restify-cors-middleware --save-dev
Once installed, in your main Restify file (mine is called
app.ts), you can import the CORS middleware (I'm using TypeScript here):
import * as corsMiddleware from "restify-cors-middleware";
Once imported, create your CORS object:
const cors = corsMiddleware({ origins: ["*"], allowHeaders: ["Authorization"], exposeHeaders: ["Authorization"] });
For testing, I'm just allowing origins from everywhere with the
*wildcard. For production, you're probably going to want to restrict access. For the two header options, I'm asking for the "Authorization" header to be available since I'm authenticating via a JSON Web Token (JWT), and will need access to the Authorization Bearer header.
Lastly, you'll need to use the
pre() and
use() methods to set up the middleware for the Restify server (my example assumes the Restify server is a variable named
server):
server.pre(cors.preflight); server.use(cors.actual);
The first sets up preflight requests, while the second adds the appropriate support for the normal requests.
Once set up, you should be able to access your API via a secondary localhost application on a different port. | https://codepunk.io/using-cors-with-restify-in-nodejs/ | CC-MAIN-2022-21 | refinedweb | 444 | 50.97 |
Hey time hacking and working on Openstack Swift the awesome OpenSource object storage cluster.
One thing I’ve been trying to tackle recently is container sharding in Swift, I will not go into full details as there is a Swift Spec that is relatively recent, and I’ve also gave a high level talk on it at LCA in Geelong.
The tl;dr being, Swift accounts and containers (or the metadata layer of Swift) are SQLite databases that get treated like objects themselves and replicated throughout the cluster. Which works amazingly well. Until you add millions and millions of objects to a container. And what I’m talking about here is container level object metadata, not the objects themselves. When this happens, SQLite being a file starts to have latency and locking issues, as one would expect. The solution to this is shard up these container databases throughout the cluster, which is what I’ve been working on.
At the last OpenStack summit in Austin, the awesome people at SwiftStack, whom I work quite closely with in the community gave me a container database they generated that has 700,000,000 objects in it (metadata again). This SQLite file is about 105G so not small. Plugging this into a small cluster I have to test my sharding implementation has been interesting to say the least.
When sharding a container down, we have a simple idea, split it in half. That is to say find someplace in the object table to pivot on. We can then keep pivoting giving us a list of ranges (which can be treated as a binary tree). The problem is finding the pivot point. In all my testing up til now I had what I thought was the perfect and simple way:
SELECT name
FROM object
WHERE deleted=0 ORDER BY name LIMIT 1 OFFSET (
SELECT object_count / 2
FROM policy_stat);
This did amazingly well in all my tests.. but I obviously never got big enough. This simple SQL statement would do plenty well if sharding in Swift was turned on from day dot, but the sharding plans for Swift is for once it’s solved in this POC to add to Swift as a beta which can be turned ‘on’ at a container by container basis when you want. After it graduates from beta but is still a switch. To finally once we are confident in it’s ability to have it on permanently. In the latter case container’s would never get big enough to worry about.. However, in the earlier stages a user would only turn it on when the container is _very_ slow.
Using the pivot SQL statement on the large container I was given ground to a halt, I’m sure it would have come back to be eventually, but I got tired of waiting after what seemed for ages.. there has to be a better way.
Turns out the OFFSET statement in SQLite, even when hitting an index still does a scan to find the offset.. This is slow when you get to a very large table size. Turns out under the hood, the resultset is stored as a double-linked list, and OFFSET will still scan down the results, which I’m sure probably has optimisations but anyway I was struggling to think of a good way to find a good enough middle value that didn’t involve some table scanning. You can see from the SQL statement, we know have many objects we have in the container, but the problem is because swift is eventually consistent we need to temporally store objects that have been deleted. So randomly picking an index doesn’t help, and it wont necessarily be in name order.
So on really large containers OFFSET needs to be thrown out the window. Turns out the sharding implementation can deal with shrinking the number of shards, merging smaller ranges together, not just growing/splitting. This means we don’t actually need to be exact, we also don’t actually need to split on an existing object, just a name that would be somewhere in the middle and so long as it’s cutting down the large container then it’s good enough. So what can we do?
Turns out there is an optimisation in SQLite, because an index is a double-linked list and ordered by it’s index, it’s really quick if all we want to do is go to the first or last element. So that’s what I’ve done:
SELECT min(name) as name FROM object WHERE deleted = 0;
SELECT max(name) as name FROM object WHERE deleted = 0;
These two statements are blindingly fast due to the fact that we already have a compound index on name and delete (for cleaning up). Note however they have to be run as 2 separate commands, combine the two into one and you loose your optimisation and you’ll have to scan all elements. Having the min and max name is a good start, and even when dealing with already sharded containers, they are just smaller ranges so this still works. The question is now what?
In the perfect work we have an even distribution of objects between the min and max names, so we just need to find a middle name between the two to pivot on. Turns out even in a not evenly distributed container we will still be shrinking the container, even at worst case only be a few objects. But these will be cleaned up later (merged into a neighbour range by the implementation). And so long as the container gets smaller, eventually it’ll shrink small enough to be usable.
Next step is finding the middle value, to do this I just wrote some python:
from itertools import izip_longest import sys lower = unicode(sys.argv[1]) upper = unicode(sys.argv[2]) def middle_str(str1, str2): result = [] for l, u in izip_longest(map(ord, str1), map(ord, str2), fillvalue=0): result.append((l + u) // 2) return u''.join(map(unichr, result)) if __name__ == "__main__": print(middle_str(lower, upper))
What does it do. Calling middle_str(min, max) will grab the unicode versions of the strings, turn them into there interger values, find the middle and turn them back into a word. After matching the prefix that is. So:
$ python middle_str.py 'aaaaaaaaa' 'zzzzzzzzz'
mmmmmmmmm
$ python middle_str.py 'aaaaaaaaa' 'aazzzzzzz'
aammmmmmm
$ python middle_str.py 'DFasjiojsaoi' 'ZZsdkmfi084f'
OPjkjkjiQLQg
I am now plugging this into my implementation and lets tackle this large container again. | https://oliver.net.au/?p=267 | CC-MAIN-2018-39 | refinedweb | 1,090 | 68.5 |
τ for some type τ (see Chapter 7). When the program is executed, the computation main is performed, and its result (of type τ)1 . For example, here is a three-module program:
It is equivalent to the following single-module program:
Because they are allowed to be mutually recursive, modules allow a program to be partitioned freely without regard to dependencies.
A module name (lexeme modid) is a sequence of one or more identifiers beginning with capital letters, separated by dots, with no intervening spaces. For example, Data.Bool, Main and Foreign.Marshal.Alloc are all valid module names.
Module names can be thought of as being arranged in a hierarchy in which appending a new component creates a child of the original module name. For example, the module Control.Monad.ST is a child of the Control.Monad sub-hierarchy. This is purely a convention, however, and not part of the language definition; in this report a modid is treated as a single identifier occupying a flat namespace. ‘module:
In all cases, the (possibly-qualified) type constructor T must be in scope. The constructor and field names ci in the second form are unqualified; one of these subordinate names is legal if and only if (a) it names a constructor or field of T , and (b) the constructor or field is in scope in the module body regardless of whether it is in scope under a qualified or unqualified name. For example, the following is legal
Data constructors cannot be named in export lists except as subordinate names, because they cannot otherwise be distinguished from type constructors.
In all cases, C must be in scope. In the second form, one of the (unqualified) subordinate names fi is legal if and only if (a) it names a class method of C, and (b) the class method is in scope in the module body regardless of whether it is in scope under a qualified or unqualified name.
Here the module Queue uses the module name Stack in its export list to abbreviate all the entities imported from Stack.
A module can name its own local definitions in its export list using its own name in the “module M” syntax, because a local declaration brings into scope both a qualified and unqualified name (Section 5.5.1). For example:).
Exports lists are cumulative: the set of entities exported by an export list is the union of the entities exported by the individual items of the list..
any constructor, class, or type named C is excluded. In contrast, using C in an import list names only a class or type.:
Imported modules may be assigned a local alias in the importing module using the as clause. For example, in
entities must be referenced using ‘C.’ as a qualifier instead of ‘Very:
This module is legal provided only that Foo and Baz do not both export f.
An as clause may also be used on an un-qualifiedimport statement:
This declaration brings into scope f and A.f.
To clarify the above import rules, suppose the module A exports x and y. Then this table shows what names are brought into scope by the specified import statement:
In all cases, all instance declarations in scope in module A are imported (Section 5.4).
A qualified name is written as modid.name (Section 2.4). A qualified name is brought into scope:
is legal. The defining occurrence must mention the unqualified name; therefore, it is illegal to write.
Many of the features of Haskell are defined in Haskell itself as a library of standard datatypes, classes, and functions, called the “Standard Prelude.” In Haskell, the Prelude is contained in the module Prelude. There are also many predefined library modules, which provide less frequently used functions and types. For example, complex numbers, arrays, and most of the input/output are all part of the standard libraries. These are defined in Part II. Separating libraries from the Prelude has the advantage of reducing the size and complexity of the Prelude, allowing it to be more easily assimilated, and increasing the space of useful names available to the programmer. ‘import 9. Some datatypes (such as Int) and functions (such as Int addition) cannot be specified directly in Haskell. Since the treatment of such entities depends on the implementation, they are not formally defined in Chapter 9. The implementation of Prelude is also incomplete in its treatment of tuples: there should be an infinite family of tuples and their instance declarations, but the implementation only gives a scheme.
Chapter: | http://www.haskell.org/onlinereport/haskell2010/haskellch5.html | CC-MAIN-2014-41 | refinedweb | 761 | 52.6 |
This tutorial walks you through small SeqAn programs. It is intended to give you a short overview of what to expect in the other tutorials and how to use this documentation.
Every page in the tutorials begins with this section. It is recommended that you do the "prerequisite tutorials" before the current one. You should also have a look at the links provided in "recommended reading" and maybe keep them open in separate tabs/windows as reference.
These tutorials try to briefly introduce C++ features not well known, however they do not teach programming in C++! If you know how to program in another language, but are not familiar with C++ and/or the significant changes in the language in recent years, we recommend the following resources:
Most good tutorials start with an easy Hello World! program. So have a look:
You may ask, why we do not use std::cout or std::cerr for console output. Actually, for the given text it does not make a difference since seqan3::debug_stream prints to std::cerr as well. However, the debug stream provides convenient output for SeqAn's types as well as widely used data structures (e.g. std::vector), which is especially helpful when you debug or develop your program (that's where the name originates).
intand initialise the vector with a few values. Then print the vector with seqan3::debug_stream. Does your program also work with std::cerr?
After we have seen the Hello World! program, we want to go a bit further and parse arguments from the command line. The following snippet shows you how this is done in SeqAn. Here the program expects a string argument in the program call and prints it to your terminal.
Implementing a program with seqan3::argument_parser requires three steps:
argcand
argvvariables.
You will see that the entered text is now in the buffer variable
input. The argument parser provides way more functionality than we can show at this point, e.g. validation of arguments and different option types. We refer you to the respective tutorial if you want to know more.
You have just been introduced to one of the Modules of SeqAn, the Argument Parser. Modules structure the SeqAn library into logical units, as there are for instance
alignment,
alphabet,
argument_parser,
io,
search and some more. See the API Reference (Modules) section in the navigation column for a complete overview.
Some modules consist of submodules and the module structure is represented by the file hierarchy in the
include directory. Whenever you use functions of a module, make sure to
include the correct header file. Each directory in the SeqAn sources contains an
all.hpp file which includes all the functionality of the respective (sub-) module. For small examples and quick prototyping, you can just include these
all.hpp-headers. However, for larger projects we recommend you include only the necessary headers, because this will reduce the compile time measurably.
Let's look at some functions of the IO module: SeqAn provides fast and easy access to biological file formats. The following code example demonstrates the interface of seqan3::sequence_file_input.
Can you imagine anything easier? After you have initialised the instance with a filename, you can simply step through the file in a for loop and retrieve the fields via structured bindings. The returned fields are
SEQ,
ID and
QUAL to retrieve sequences, ids and qualities, respectively. The latter is empty unless you read FastQ files. The appropriate file format is detected by SeqAn from your filename's suffix.
Here is the content of
seq.fasta, so you can try it out!
./myprogram seq.fasta).
Note that the same code can also read FastQ files and the
qual variable will not be empty then. If you like, try it!
snake_casefor almost everything, also class names. Only C++ concepts are named using
CamelCase.
We have two sequences from the file above now – so let us align them. The pairwise sequence alignment is one of the core algorithms in SeqAn and used by several library components and apps. It is strongly optimised for speed and parallel execution while providing exact results and a generic interface.
The algorithm returns a range of result objects – which is the reason for the loop here (in this case the range has length 1). Instead of passing a single pair of sequences, we could give a vector of sequence pairs to the algorithm which then executes all alignments in parallel and stores the results in various seqan3::alignment_result objects. The second argument to seqan3::align_pairwise is the configuration which allows you to specify a lot of parameters for the alignment computation, for instance score functions, banded alignment and whether you wish to compute a traceback or not. The configurations have their own namespace seqan3::align_cfg and can be combined via the logical OR operator (
|) for building combinations. Check out the alignment tutorial if you want to learn more.
using namespace seqan3;. This has the additional benefit of easily distinguishing between library features and standard C++. The only exception are string literals, where we often use
using namespace seqan3::literalsfor convenience.
<>). We also always use
{}to initialise objects and not
()which is only used for function calls. In general the style should be much easier for newcomers.
Now that you reached the end of this first tutorial, you know how SeqAn code looks like and you are able to write some first code fragments. Let's go more into detail with the module-based tutorials! | https://docs.seqan.de/seqan/3-master-user/tutorial_first_example.html | CC-MAIN-2021-21 | refinedweb | 916 | 56.45 |
Last week Yashh pinged me about starting to write a Python wrapper for Brightkite. Based on the Brightkite restful api we've managed to make some fairly respectable progress towards a working library.
You can contribute or check it out in it's GitHub repository, and can see remaining tasks in the wiki.
Installing Python-Brightkite
Installing Python-Brightkite is a fairly straightforward process.
easy_install httplib2 git clone git://github.com/lethain/python_brightkite.git
It also depends upon xml2dict, but that dependency is packaged along with it (we're packaging it because it doesn't have an easy_install package, and hasn't changed in a couple of years).
For the time being you'll probably do best to copy the
.py files
from the repository into your project, but we'll solidify a more humane
deployment solution as the project reaches the toddler stage of development.
cp python_brightkite/*.py ~/path/to/your/project/
Promise it'll get smoother Real Soon Now.
Using Python-Brightkite
Python-Brightkite is pretty straightforward to use, although the ridiculous quantity of APIs exposed by Brightkite means that you may have to wade around looking for the right API.
>>> from bk import Brightkite x >>> x = Brightkite("lethain","some-password") >>> x.friends() {'friends': {'person': {'last_checked_in_as_words': {'value': '9 days'}, 'last_active_at': {'type': {'value': 'datetime'}, 'value': '2008-11-07T03:44:03Z'}, 'tiny_avatar_url': {'value': ''}, 'value': '\n ', 'last_checked_in': {'type': {'value': 'datetime'}, 'value': '2008-11-07T03:44:03Z'}, 'small_avatar_url': {'value': ''}, 'place': {'name': {'value': 'Middlefield Station (1)'}, 'display_location': {}, 'longitude': {'type': {'value': 'float'}, 'value': '-122.051959'}, 'value': '\n ', 'latitude': {'type': {'value': 'float'}, 'value': '37.39607'}, 'scope': {'value': 'country'}, 'id': {'value': '522478caac7e11dd979a003048c0801e'}}, 'smaller_avatar_url': {'value': ''}, 'fullname': {'value': 'Yashh'}, 'login': {'value': 'yashh'}}, 'type': {'value': 'array'}, 'value': '\n '}} >>> results = x.places_search("new york") >>>']['id'] {'value': 'ede07eeea22411dda0ef53e233ec57ca'} >>> results['place']['id']['value'] 'ede07eeea22411dda0ef53e233ec57ca'
So, those are two of the twenty four APIs implemented thus far in Python-Brightkite. For all of them we are directly translating the XML files into Python datastructures, so you'll need to look at the returned datastructure or raw XML to figure out the structure of the returned data for each API.
Limitations of Python-Brightkite
We've actually managed to implement a majority of the functionality exposed by the Brightkite restful API, but there are a few minor blips, and one major blop.
Specifically, all the data retrieval commands have been tested, but the creation/deletion/updating aspects haven't really been trialed much (but the code is pretty much drop-dead simple, so fixing any problems shouldn't take more than a few minutes after they've been identified).
The one big missing piece of functionality is using OAuth for authentication. Since the only other option is HTTP Basic Auth, that's currently all that Python-Brightkite supports. Before Python-Brightkite can be used seriously, this limitation will need to be resolved. If you're interested in looking into that, there are resources like this snippet and this library. I might marshall the necessary mental resources next weekend if it hasn't been resolved by then.
A Few Notes on Implementation
This was a pretty fun and quick project to put together (keeping in mind that Yashh contributed to the project as well). After trying out XML::Simple, I am pretty convinced that converting XML into native datastructures is the right way to deal with XML unless performance is a big deal for your use case.
Using xml2dict (which I first saw in Vik Singh's library for using Yahoo! BOSS), which translates XML documents into Python
datastructures, along with httplib2 made the foundation of
the app pretty short and sweet. (Be kind and ignore the awfulness of the
_unescape_uri method. It was the ten second fix to realizing
I had escaped too aggressively, but wanted to see if the overall
library would work.)
def _unescape_uri(self, uri): return uri.replace("%3A",":").replace("%3F","?").replace("%26","&").replace("%3D","=") def _get(self, uri): "Fetch content via the GET method. Returns body of returned content." uri = self._unescape_uri(uri) header, content = self.http.request(uri, "GET") return content def _post(self, uri, content={}): uri = self._unescape_uri(uri) header, content = self.http.request(uri, "POST", body=content) return content def _delete(self, uri): uri = self._unescape_uri(uri) header, content = self.http.request(uri, "DELETE") return content def _convert_xml(self, xml): "Stub method." try: return self.xml.fromstring(xml) except ExpatError: msg = "Couldn't parse response from Brightkite API." raise BrightkiteException(msg, xml)
Built on those five methods, the API calls are all very simple. Here are a pair of representative ones:
def friends(self, username=None): "Fetch friends for specified user, or self if no user specified." username = username or self.user uri = "" % username return self._convert_xml(self._get(quote(uri))) def checkin(self, place_hash): "Checkin at given specified position." uri = "" % place_hash self._post(uri)
Really, that's all there is to the implementation other than
the constructor and the implementation of the
http and
xml
properties.
I can remember thinking, some time back, about how sweet it was that people put together wrapper libraries around APIs like Amazon's or Facebook's. Then I started to realize that implementing a wrapper API is mostly a matter of time, not talent. Now that I've played around with a couple, I've started realizing that even further it's less a matter of time, and more a matter of just doing it. (Although, maintaining wrapper libraries will try to kill you.)
If we could just find a universal format for describing APIs, then we'd be able to just bypass writing wrapper libraries altogther. That way, even if the developers didn't write the API spec, it would just take a couple of developers a couple of hours to write it up, and then we'd have pretty wrapper libraries for even the most bleeding edge of APIs. So much possibility, so little time. | http://lethain.com/python-brightkite-for-using-brightkite-in-python/ | CC-MAIN-2014-52 | refinedweb | 977 | 55.24 |
This article aims to show how a multi-step procedure for collecting user input could be implemented in Silvelight 2.0 Beta.
In developing business applications, you soon realise that users need simple and self-guiding UIs in order to complete even really simple tasks. When a multitude of fields must be completed and not all of that can fit in a single form/window, we are forced to split those by some sort of criteria and place them in different forms. Sometimes, some of the input will effect the choices available for other fields, so those fields are pushed further down the UI. MFC has the classes CPropertySheet and CPropertyPage to aid in resolving such issues. Combining those two classes, we could create a modal window with a set of buttons that allows users to flip through pages of input field, and we would put the dependent fields in pages that are further away.
CPropertySheet
CPropertyPage
Silverlight does not provide such a feature, and nor do the .NET standard libraries. I will shortly describe how to do just that.
Here is how my implementation looks like, with some extra demo UI added for completeness:
The main player is the Wizard (UserControl); it lays out the familiar UI for the user, with two buttons at the right bottom, a title bar, and a pages area. This is achieved using a grid with 3X3 cells. The middle cell 1,1 is reserved for pages. This cell is assigned a SwitcherControl (UserControl) that has no UI content of its own. The SwitchPage(UserControl oControl) function is used to switch pages on the SwitcherControl.
Wizard
UserControl
SwitcherControl
SwitchPage(UserControl oControl)
The Wizard class is added a Pages attached property that enables us to bind to it and to also add pages through XAML.
Pages
Whenever one of the two buttons is clicked, the wizard fires a predefined PageEvent that enables the host page to monitor wizard activity. The WizardEventArgs passes the current page index, the new page index, button action (previous, next, and finish) and an optional Cancel property. This event is fired before the page is changed; setting the Cancel property to true will stop the intended transition.
PageEvent
WizardEventArgs
Cancel
true
I have tried to encapsulate as much functionality as necessary to demonstrate the point in the Wizard class while following the OO design paradigm, and as little as not to clutter it too much with unnecessary code.
In this project, I have decided to involve as much of Binding as possible, as it makes the implementation cleaner and easier to follow.
We could also easily add the following;
Start by creating your own page (MainPage); import the wizard namespace in XAML. In the code below, I have alias-ed the namespace as "sl". Within the section/container you wish to place the wizard, add the following XAML;
sl
<sl:Wizard x:
The code above specifies that we are placing the wizard in grid row 0; we have given it an instance name of "ctrlWizard", and we have set the title property to "Test Wizard".
ctrlWizard
Adding three pages to the wizard through XAML is shown below:
<sl:Wizard x:
<sl:Wizard.Pages>
<sl:WizardPage1 x:
<sl:WizardPage2 x:
<sl:WizardPage3 x:
</sl:Wizard.Pages>
</sl:Wizard>
We can do the same in code; e.g., in the in Loaded event of the MainPage.
Loaded
ctrlWizard.Pages.Add(new WizardPage1());
ctrlWizard.Pages.Add(new WizardPage2());
ctrlWizard.Pages.Add(new WizardPage3());
Below is the implementation of the PageEvent handler:
void OnPageEvent(Wizard sender, WizardEventArgs e)
{
_txtMsg.Text = string.Format("Action: {0}, Current: {1}, New: {2}",
e.Action, e.CurrentPageIndex, e.NewPage. | https://www.codeproject.com/Articles/29714/Silverlight-Wizard | CC-MAIN-2017-43 | refinedweb | 609 | 61.16 |
Windows 7, using .NET to run MonoDevelop
(1) Start new console project in MD
(2) Add reference to System.Windows.Forms
(3) Go to the using section and type "using System." and trigger autocomplete... Windows.Forms will not be in the list.
(4) Try typing out "using System.Windows.Forms;" without autocomplete help. The "Windows.Forms" part will be highlighted red. It will build properly, but still be highlighted red.
(5) Close and reopen solution (don't even need to restart MD). Autocompleting the namespace and the highlighting will work as expected.
Did you enable the experimental xbuild/msbuild build engine?
Sorry, yes, XBuild/MSBuild must be enabled to trigger the bug.
*** This bug has been marked as a duplicate of bug 1077 *** | https://bugzilla.xamarin.com/10/10301/bug.html | CC-MAIN-2021-39 | refinedweb | 123 | 63.25 |
In this problem, we are given an array of strings and we have to print all pairs of anagrams of that given array.
Anagrams are strings that are formed by rearranging the character of another string. Like − hello and lolhe
Let’s take an example to understand the problem −
Input: array = {“hello”, “hrdef”, “from”, “lohel”, “morf”}. Output: [hello, lohel] , [from , morf]
To solve this problem, we will use the nesting of loops. We need two nested loops, the outer loop will traverse over the array and select elements. The nested loop will check each of the string and check if they are anagrams or not.
Let’s see the program to implement that algorithm −
#include <iostream> using namespace std; #define NO_OF_CHARS 256 bool isAnagramString(string str1, string str2){ int count[NO_OF_CHARS] = {0}; int i; for (i = 0; str1[i] && str2[i]; i++){ count[str1[i]]++; count[str2[i]]--; } if (str1[i] || str2[i]) return false; for (i = 0; i < NO_OF_CHARS; i++) if (count[i]) return false; return true; } void printAnagrams(string arr[], int n){ for (int i = 0; i < n; i++) for (int j = i+1; j < n; j++) if (isAnagramString(arr[i], arr[j])) cout<<arr[i]<<" and "<<arr[j]<<" are anagrams.\n"; } int main(){ string arr[] = {"hello", "hrdef", "from", "lohel", "morf"}; int n = sizeof(arr)/sizeof(arr[0]); printAnagrams(arr, n); return 0; }
hello and lohel are anagrams. from and morf are anagrams.
This solution is quite easy to understand but is less efficient. So there can be some optimizations that can be made to our solutions to make it more effective. We can do it by sorting our array that contains a string. This sorted array will make anagram find easier. | https://www.tutorialspoint.com/print-all-pairs-of-anagrams-in-a-given-array-of-strings-in-cplusplus | CC-MAIN-2021-43 | refinedweb | 284 | 68.3 |
kell's 4 Letter Word
Please log in to add your comment.
Transcript of Haskell's 4 Letter Word
Haskell's 4 Letter Word
Who am I?
Programmer
Blues Guitarist
Origami Professional
Creole Chef Extraordinaire
Is Testing Necessary? Haskell programs which compile "just work"
No, they don't. No one actually thinks this. Please kill this meme.
Java
σ type scheme
τ known type
Γ type environment
⊦ assertion
: assumption
- judgement
What's a type?
x
add 1 2
take 4 "hello"
3.14159
"Hello, Prezi!"
\x -> x + 1
let x = 4
in x + 3
qsort :: Ord a => [a] -> [a]
qsort [] = []
qsort (x:xs) =
qsort lhs ++ [x] ++ qsort rhs
where lhs = filter (< x) xs
rhs = filter (>= x) xs
Exhaustive. The qsort function will return a value of type [a] for all possible input values of type [a]
No null pointer exceptions!
But - the type is not strong enough to prove qsort correct.
data Empty
data NonEmpty
data SafeList a b where
Nil :: SafeList a Empty
Cons :: a -> SafeList a b -> SafeList a NonEmpty
data Zero
data Succ n
data SafeList a b where
Nil :: SafeList a Zero
Cons :: a -> SafeList a b -> SafeList a (Succ b)
Only discriminates between Nil and all other lists
Somewhat cumbersome to use
Too much type information!
Way worse in every respect
Dependent type system will make it slightly easier to write functions - but is still quite difficult
[ 1, 2, 3 ] :: SafeList Int (Succ (Succ (Succ Zero)))
Further in this direction lies the subject of someone else's talk ...
Unit Testing
Haskell's type system *does* cover many cases that would be left to unit testing in other languages - but ...
Help isolate the location of a defect to a single function (ideally - more to come)
Can be written in isolation (and therefore incrementally) and assist in reasoning about your code (TDD)
Haskell functions are already pure - no chance of accidently launching missles in a unit test.
Show & Read type classes make generating test data very easy.
Make lots of green! Programmers love green!
Can create alot of noise in your test suite, requiring additional scripting to maintain your data.
Brittle. Has roughly a 1:1 correspondence with the implementation, doubling your workload.
No ability to mock without bizarre function dicitonary passing tricks, somewhat obscuring property of isolation.
it "should type check user data types" $ assertCheck
(TypExpr (TypeSymP "Cons")
(TypeAbsP (TypeApp (TypeApp (TypeSym (TypeSymP "->"))
(TypeVar (TypeVarP "a")))
(TypeApp (TypeApp (TypeSym (TypeSymP "->"))
(TypeApp (TypeSym (TypeSymP "List"))
(TypeVar (TypeVarP "a"))))
(TypeApp (TypeSym (TypeSymP "List"))
(TypeVar (TypeVarP "a"))))))
(TypExpr (TypeSymP "Nil")
(TypeAbsP (TypeApp (TypeSym (TypeSymP "List"))
(TypeVar (TypeVarP "a"))))
(LetExpr (Sym "length")
(AbsExpr (Sym "n")
(MatExpr (VarExpr (SymVal (Sym "n")))
[ (ValPatt (ConVal (TypeSym (TypeSymP "Nil"))), VarExpr (LitVal (NumLit 0.0)))
, (ConPatt (TypeSymP "Cons")
[ ValPatt (SymVal (Sym "_"))
, ValPatt (SymVal (Sym "xs")) ]
, AppExpr (AppExpr (VarExpr (SymVal (Sym "+")))
(VarExpr (LitVal (NumLit 1.0))))
(AppExpr (VarExpr (SymVal (Sym "length")))
(VarExpr (SymVal (Sym "xs")))))]))
(AppExpr (VarExpr (SymVal (Sym "length")))
(AppExpr (AppExpr (VarExpr (ConVal (TypeSym (TypeSymP "Cons"))))
(VarExpr (LitVal (NumLit 1.0))))
(AppExpr (AppExpr (VarExpr (ConVal (TypeSym (TypeSymP "Cons"))))
(VarExpr (LitVal (NumLit 2.0))))
(VarExpr (ConVal (TypeSym (TypeSymP "Nil"))))))))))
Nothing
data Cons: a -> List a -> List a
data Nil: List a
let length n =
match n with
Nil = 0
(Cons _ xs) = 1 + length xs
length (Cons 1 (Cons 2 Nil))
Step back - how to cabal
You'll need a library, even if you're writing an executable. Be sure to expose every module you intend to test via the exposed-modules section.
library
hs-source-dirs: src
exposed-modules: Tested
other-modules: Tested.Utils
build-depends: base
ghc-options: -Wall
You'll need a test-suite section. This needs all libraries that you will require to write your test bodies, but not the functions themselves.
test-suite tested-tests
type: exitcode-stdio-1.0
hs-source-dirs: tests, src
main-is: MainTestSuite.hs
build-depends: base,
HUnit,
QuickCheck,
hspec,
test-framework,
test-framework-hunit,
test-framework-quickcheck2
exitcode-stdio-1.0
Name: foo
Version: 1.0
License: BSD3
Cabal-Version: >= 1.9.2
Build-Type: Simple
Test-Suite test-foo
type: exitcode-stdio-1.0
main-is: test-foo.hs
build-depends: base
module Main where
import System.Exit (exitFailure)
main = do
putStrLn "This test always fails!"
exitFailure
detailed-1.0 (actually, detailed-0.9)
Name: bar
Version: 1.0
License: BSD3
Cabal-Version: >= 1.9.2
Build-Type: Simple
Test-Suite test-bar
type: detailed-1.0
test-module: Bar
build-depends: base, Cabal >= 1.9.2
module Bar ( tests ) where
import Distribution.TestSuite
tests :: IO [Test]
tests = return [ Test succeeds, Test fails ]
where
succeeds = TestInstance
{ run = return $ Finished Pass
, name = "succeeds"
, options = []
, setOption = \_ _ -> Right succeeds
}
fails = TestInstance
{ run = return $ Finished $ Fail "Always fails!"
, name = "fails"
, options = []
, setOption = \_ _ -> Right fails
}
spec :: Spec
spec = do
describe "Ohml.Parser" $ do
it "should compile & run match expressions" $ assertNode
" let fib = fun n -> \
\ match n with \
\ 0 -> 0; \
\ 1 -> 1; \
\ n -> fib (n - 1) + fib (n - 2);; \
\ fib 7 "
(Right "13\n")
hspec specifications
Integrates HUnit, QuickCheck and SmallCheck, and look like this
hspec-discover via preprocessor
{-# OPTIONS_GHC -F -pgmF hspec-discover #-}
module Spec where
test = 1
test/FooSpec.hs
test/Foo/BarSpec.hs
test/BazSpec.hs
main :: IO ()
main = hspecX $ do
describe "Foo" $ do
FooSpec.spec
describe "Bar"
Foo.BarSpec.spec
describe "Baz"
BazSpec.spec
HUnit
type Assertion = IO ()
assertFailure :: String -> Assertion
assertFailure msg = ioError (userError ("HUnit:" ++ msg))
Property based testing via QuickCheck
spec = do
describe "Functions in the Lists module form Prelude" $ do
describe "The `reverse` function" $
it "Applying `reverse` twice should return you the same input" $
property $ \xs -> reverse (reverse xs) == xs
To GHCi!
Conditional Property Testing via QuickCheck
ordered xs = and (zipWith (<=) xs (drop 1 xs))
insert x xs = takeWhile (<x) xs++[x]++dropWhile (<x) xs
spec = describe "The order-preserving insert function" $
it "should hold that inserting into an ordered list results in an ordered list" $
property $ \ x xs -> ordered xs ==> ordered (insert (x :: Int) xs)
... but be careful you have reasonable assumptions about your test data distribution:
spec = describe "The order-preserving insert function" $
it "should hold that inserting into and ordered list results in an ordered list" $
property $ \x xs ->
ordered xs ==>
trivial (null xs) $
collect (length xs) $
classify (ordered (x:xs)) "at-head" $
classify (ordered (xs++[x])) "at-tail" $
ordered (insert x xs)
Property testing over your own datatypes via QuickCheck
choose :: Random a => (a, a) -> Gen a
genEl :: [a] -> Gen a
genEl xs = choose (0, length xs-1) >>= (!! i)
next :: Gen a -> (a, Gen a)
oneof :: [Gen a] -> Gen a
frequency :: [(Int, Gen a)] -> Gen a
inc 1
Property testing your own datatypes via the arbitrary type class ... via QuickCheck
instance Arbitrary Sym where
arbitrary = (Sym . (:[])) `fmap` choose ('a', 'z')
instance Arbitrary Lit where
arbitrary = oneof [ StrLit `fmap` oneof (return `fmap` arbitrary)
, NumLit `fmap` oneof (return `fmap` arbitrary) ]
instance Arbitrary Val where
arbitrary = oneof [ SymVal `fmap` arbitrary
, LitVal `fmap` arbitrary ]
instance Arbitrary Expr where
arbitrary = sized expr'
where
expr' 0 = VarExpr `fmap` arbitrary
expr' n = oneof [ liftM3 LetExpr arbitrary subExpr subExpr
, liftM2 AppExpr subExpr subExpr
, liftM2 AbsExpr arbitrary subExpr
, liftM VarExpr arbitrary ]
where subExpr = expr' (n `div` 2)
DocTest
-- | Compute Fibonacci numbers
--
-- Examples:
--
-- >>> fib 10
-- 55
--
-- >>> fib 5
-- 5
fib :: Int -> Int
fib 0 = 0
fib 1 = 1
fib n = fib (n - 1) + fib (n - 2)
-- )
-- file doctests.hs
import Test.DocTest
main = doctest ["-isrc", "src/Main.hs"]
test-suite doctests
type: exitcode-stdio-1.0
ghc-options: -threaded
main-is: doctests.hs
build-depends: base, doctest >= 0.8
Example
let g = \x -> add x 4
in g 2
`add` must be type `a -> b -> c`
it is known that `add` is type `Num -> Num -> Num`
therefore `a`, `b`, `c` are type `Num`
therefore `\x -> add x 4` must be type `a -> c`
therefore `g` must be type `a -> c`
therefore `a` must be type `Num`
therefore the program must be type Num
Introduce an `Assumption` for every symbol in a program, binding the symbol's name & scope to it's type, which may be a variable.
Walk the expression tree using these assumptions, and introduce a `Substitution` for every usage of a symbol, to fit its context.
Where we assign or abstract values, we need to `Unify` two types, by calculating the most general new substitutions which make them equivalent.
Where we want to use a variable in a polymorphic way, we'll need to `Generalize` some assumptions so they can be instantiated with a fresh set of type variables for every usage.
Algorithm
DocTest (cont)
Decidable
Turing Incomplete
Inferrable
Will always calculate the Principal Type
data TestSet = TS (M.Map String Int) [String] [String] deriving (Show)
instance Arbitrary TestSet where
arbitrary = do common <- (filter (/="")) <$> arbitrary
known <- (filter (/="")) <$> arbitrary
unknown <- (filter (/="")) <$> arbitrary
counts <- ((map ((+1) . abs)) . (cycle . (++[1]))) <$> arbitrary
return $ TS (M.fromList (zipWith (,) (known ++ common) counts)) (unknown ++ common) common
prop_idemp (TS d w _) = spellCheck (D d) w == spellCheck (D d) (spellCheck (D d) w)
Another Example, Spellchecking
Spellchecking random words against a random dictionary may not work so well ....
data Expr = LetExpr Sym Expr Expr -- let x = 1 in x
| AppExpr Expr Expr -- f a
| AbsExpr Sym Expr -- fun x -> x
| VarExpr Val -- x
data Val = SymVal Sym
| LitVal Lit
data Lit = StrLit String
HPC
Simply add `-fhpc` to your ghc-options section of your test-suite, and your tests will generate `.tix` and `.mix` files suitable for analysis
EXCEPT NOT REALLY - because hpc integration with cabal is currently broken. Sorry!
An aside about IO ...
getList = find 5 where
find 0 = return []
find n = do
ch <- getChar
if ch `elem` ['a'..'e'] then do
tl <- find (n-1)
return (ch : tl) else
find n
-- A thin monadic skin layer
getList :: IO [Char]
getList = fmap take5 getContents
-- The actual worker
take5 :: [Char] -> [Char]
take5 = take 5 . filter (`elem` ['a'..'e'])
Coarbitrary
class CoArbitrary where
coarbitrary :: a -> Gen c -> Gen c
A note about Shrinkage
shrink :: a -> [a]
shrink = subsequences
eg, for Lists
dropFirstElementNumberOfElements :: [Int] -> [Int]
Without generalization step, the application of `f 1` will introduce the assumption `f : Num -> Num`, which makes the rest of the expression invalid.
Generalization will guarantee that each application of `f` will have new type variables, by replacing the type variable representing `x` with a fresh var at every invocation.
let f = \x -> x
in f 1 == f 1 && f \"test\" == f "test"
Generalization | http://prezi.com/oykubo5szwe3/haskells-4-letter-word/ | CC-MAIN-2014-15 | refinedweb | 1,717 | 51.28 |
Represents a directed graph which is embeddable in a planar surface. More...
#include <geos/planargraph.h>
Represents a directed graph which is embeddable in a planar surface.
This class and the other classes in this package serve as a framework for building planar graphs for specific algorithms. This class must be subclassed to expose appropriate methods to construct the graph. This allows controlling the types of graph components (DirectedEdge, Edge and Node) which can be added to the graph. An application which uses the graph framework will almost always provide subclasses for one or more graph components, which hold application-specific data and graph algorithms.
Adds a node to the std::map, replacing any that is already at that location.
Only subclasses can add Nodes, to ensure Nodes are of the right type.
References geos::planargraph::NodeMap::add().
Adds the Edge and its DirectedEdges with this PlanarGraph.
Assumes that the Edge has already been created with its associated DirectEdges. Only subclasses can add Edges, to ensure the edges added are of the right class.
Adds the Edge to this PlanarGraph.
Only subclasses can add DirectedEdges, to ensure the edges added are of the right class.
Returns an Iterator over the DirectedEdges in this PlanarGraph, in the order in which they were added.
Get all Nodes with the given number of Edges around it.
Found nodes are pushed to the given vector
Returns the Edges that have been added to this PlanarGraph.
Returns the Nodes in this PlanarGraph.
References geos::planargraph::NodeMap::getNodes().
Removes an Edge and its associated DirectedEdges from their from-Nodes and from this PlanarGraph.
Note: This method does not remove the Nodes associated with the Edge, even if the removal of the Edge reduces the degree of a Node to zero.
Removes DirectedEdge from its from-Node and from this PlanarGraph.
Note: This method does not remove the Nodes associated with the DirectedEdge, even if the removal of the DirectedEdge reduces the degree of a Node to zero. | https://geos.osgeo.org/doxygen/classgeos_1_1planargraph_1_1PlanarGraph.html | CC-MAIN-2019-09 | refinedweb | 331 | 64.51 |
Users merge of newforms-admin back before Django 1.0, you can and it’s really really easy; in fact, it’s even documented. But still it’s probably the #1 most-frequently-asked question about the admin.
So as I’m stuck in a hotel overnight with nothing better to do (thanks to the gross incompetence of Delta Airlines), consider this my attempt to give the Django community an early Christmas present by walking through the process step-by-step and demonstrating just how trivially simple it is to do this. And next time you see someone asking how to accomplish this, please point them at this article.
For a free bonus Christmas present, I’ll also explain another frequently-requested item: how to ensure that people can only see/edit things they “own” (i.e., that they created) in the admin.
But first…
A big fat disclaimer: there are lots and lots of potential uses for these types of features. Many of them are wrong and stupid and you shouldn’t be trying them.
I say this because a huge number of the proposed use cases for this type of automatic filling-in of users and automatic filtering of objects boil down to “I’ve let these people into my admin, but I still don’t trust them”. And that’s a problem no amount of technology will solve for you: if you can’t rely on your site administrators to do the right thing, then they shouldn’t be your site administrators.
Also, you will occasionally see someone suggest that these features can be obtained by what’s known as the “threadlocal hack”; this basically involves sticking
request.user into a sort of magical globally-available variable, and is a Very Bad Thing to use if you don’t know what you’re doing. It’s also generally a Very Bad Thing to use even if you do know what you’re doing, since you’re probably just doing it because you’re lazy and don’t feel like ensuring you pass information around properly. So if you see someone suggesting that you do this using a “threadlocal”, ignore that person.
Now. Let’s get to work.
Automatically filling in a user
Consider a weblog, with an
Entry model which looks like this:
import datetime from django.contrib.auth.models import User from django.db import models class Entry(models.Model): title = models.CharField(max_length=250) slug = models.SlugField() pub_date = models.DateTimeField(default=datetime.datetime.now) author = models.ForeignKey(User, related_name='entries') summary = models.TextField(blank=True) body = models.TextField() class Meta: get_latest_by = 'pub_date' ordering = ('-pub_date',) verbose_name_plural = 'entries' def __unicode__(self): return self.title def get_absolute_url(self): return "/weblog/%s/%s/" % (self.pub_date.strftime("%Y/%b/%d"), self.slug)
Our first goal is to write a
ModelAdmin class for the
Entry model, such that each new
Entry being saved will automatically fill in the “author” field with the
User who created the
Entry. We can start by filling out the normal options for the
ModelAdmin in the blog application’s
admin.py file:
from django.contrib import admin from blog.models import Entry class EntryAdmin(admin.ModelAdmin): list_display = ('title', 'pub_date', 'author') prepopulated_fields = { 'slug': ['title'] } admin.site.register(Entry, EntryAdmin)
And since we’re going to automatically fill in the
author field, let’s go ahead and leave it out of the form:
class EntryAdmin(admin.ModelAdmin): exclude = ('author',) list_display = ('title', 'pub_date', 'author') prepopulated_fields = { 'slug': ['title'] }
All that’s left now is to override one method on
EntryAdmin. This method is called
save_model, and it receives as arguments the current
HttpRequest, the object that’s about to be saved, the form being used to validate its data and a boolean flag indicating whether the object is about to be saved for the first time, or already exists and is being edited. Since we only need to fill in the
author field on creation, we can just look at that flag. The code ends up looking like this:
def save_model(self, request, obj, form, change): if not change: obj.author = request.user obj.save()
That’s it: all this method has to do is save the object, and it’s allowed to do anything it wants prior to saving. And since it receives the
HttpRequest as an argument, it has access to
request.user and can fill that in on the
Entry before saving it. This is documented, by the way, and the documentation is your friend.
Showing only entries someone “owns”
The other half of the puzzle, for most folks, is limiting the list of viewable/editable objects in the admin to only those “owned by” the current user; in our example blog application, that would mean limiting the list of entries in the admin changelist to only those posted by the current user. To accomplish this we’ll need to make two changes to the
EntryAdmin class: one to handle the main list of objects, and another to make sure a malicious user can’t get around this and edit an object by knowing its ID and jumping straight to its edit page.
First, we override the method
queryset on
EntryAdmin; this generates the
QuerySet used on the main list of
Entry objects, and it gets access to the
HttpRequest object so we can filter the entries based on
request.user:
def queryset(self, request): return Entry.objects.filter(author=request.user)
Of course, there’s a problem with this: it completely hides every entry except the ones you yourself have written, we probably want an ability for a few extremely trusted people to still see and edit other folks’ entries. Most likely, these people will have the
is_superuser flag set to
True on their user accounts, so we can show them the full list and only filter for everybody else:
def queryset(self, request): if request.user.is_superuser: return Entry.objects.all() return Entry.objects.filter(author=request.user)
This only affects the entries shown in the list view, however; a different method —
has_change_permission — is called from the individual object editing page, to ensure the user is allowed to edit that object. And that method, by default, returns
True if the user has the “change” permission for the model class in question, so we’ll need to change it to check for the class-level permission, then check to see if the user is a superuser or the author of the entry. Here’s the code (this method receives both the
HttpRequest and the object as arguments):
And finally, here’s the completed
admin.py file containing the full class:
from django.contrib import admin from blog.models import Entry class EntryAdmin(admin.ModelAdmin): exclude = ('author',) list_display = ('title', 'pub_date', 'author') prepopulated_fields = { 'slug': ['title'] } def queryset(self, request): if request.user.is_superuser: return Entry.objects.all() return Entry.objects.filter(author=request.user) def save_model(self, request, obj, form, change): if not change: obj.author = request.user obj.save() admin.site.register(Entry, EntryAdmin)
And that’s it
No, really. Although this ends up generating huge numbers of “how do I do it” questions, it really is that easy.
And if you’re curious, there are plenty more interesting methods on
ModelAdmin you can tinker with to get even more interesting and useful behavior out of the admin; you can do a lot worse than to sit down some night with the source code (
django/contrib/admin/options.py) and read through it to get a feel for what’s easily overridden. | https://www.b-list.org/weblog/2008/dec/24/admin/ | CC-MAIN-2019-04 | refinedweb | 1,255 | 53.81 |
#include <sys/types.h> #include <sys/mman.h> #include <sys/vm.h> #include <sys/ddi.h>
ppid_t prefixmmap(void *idata, channel_t channel, size_t offset, int prot);
This entry point maps one page, at the specified relative logical offset within the device's memory. This offset space may be different from offsets used for normal I/O; therefore, it is the driver's responsibility to validate offsets.
Valid values for prot are:
A physical page ID is a machine-specific token that uniquely identifies a page of physical memory in the system (either kernel memory or device memory). To get the physical page ID for a given virtual address, use the kvtoppid(D3) function. To get the physical page ID for a given physical address, use the devmem_ppid(D3) function.
No assumptions should be made about the format of a physical page ID.
After mmap( ) returns successfully, the mapping remains in use until the device instance is closed, which is the next last close for this device instance. Any memory so mapped must not be freed until after the device instance is closed.
int prefixmmap(dev_t dev, off_t offset, int prot);dev is the device number for the device to be mapped.
In DDI versions prior to version 8, mmap( ) is only available to character device drivers and is a named entry point, so must be defined as a global symbol.
d_mmapmember of their drvops(D4) structure.
Named entry point routines must be declared in the driver's Master(DSP/4dsp) file. The declaration for this entry point is $entry mmap. This applies only to non-STREAMS drivers that use DDI versions prior to version 8.
``Memory-mapped I/O'' in HDK Technical Reference | http://osr600doc.xinuos.com/en/man/html.D2/mmap.D2.html | CC-MAIN-2022-21 | refinedweb | 283 | 56.86 |
Vue.js 2 State Management With Vuex – Introduction
DemoCode to inform other components about data changes. If you applications grows bigger keeping track if all those events becomes difficult and it’s hard to keep the overview of components which need to trigger events and components which need to listen to those events.
To solve that problem you can use Vuex which makes it possible to use a centralized state management in your application. Vuex is a library which helps you to enforce a Flux-like application architecture in your Vue.js 2 application.
So what exactly is meant by state and centralized state management? Simply, you can think of state as just data you use in your application. So a centralized state is just data you’re using by more than one component (application level state).
Vuex introduces a centralized state management by implementing the following core concepts (Store concept):
- State Tree: An object containing the data
- Getters: Used to access data from the state tree of the store
- Mutations: Handler functions that perform modifications of data in the state tree
- Actions: Functions that commit mutations. The main difference to Mutations is that Actions can contain asynchronous operations
Don’t worry if this concept seems a little bit strange at first. We’ll explore the various building blocks in detail in the following. Take a look at this diagram form the Vuex docs:
This overview is great for understanding the flows of actions and data in the store concept. From the diagram you can see that the data flow is unidirectional. A Vue component initiates a state change by dispatching an Action. The Action method can be used to perform asynchronous operation (e.g. accessing a web service to retrieve data) and then commit a Mutation. The Mutation performs the modification of the state tree. A new state becomes available is used by components to display the changed data.
Let’s see how everything works by building a sample application next.
Setting Up A Vue.js 2 Project And Installing Vuex
The easiest way to set up a new Vue.js 2 project is to use Vue CLI. To install Vue CLI on your system use the following command:
$ npm install --global vue-cli
Now we’re ready to use the vue command to initiate a new Vue project:
$ vue init webpack vuex-test-01
Next, change into the newly created project folder:
$ cd vuex-test-01
Use NPM to install the default dependencies
$ npm install
Finally you can start up the development web server by using the npm command in the following way:
$ npm run dev
In the next step we need to add the Vuex library to the project.
Vuex is an official Vue package, but not part of the core library. If you want to use Vuex in your project, you first need to install it via NPM:
$ npm install vuex --save
This makes sure that this package is downloaded in the node_modules folder of the project and that this dependency is added to package.json file.
Creating A Store
Having installed Vuex, we’re now ready to create a first store in our application. Within the src folder create a new subfolder named store. Within that folder create a new file store.js and insert the following code:
import Vue from 'vue' import Vuex from 'vuex' Vue.use(Vuex) const state = { count: 0 } export default new Vuex.Store({ state })
First, we need to use two import statements to make Vue and Vuex available. Second, a call of
Vue.use(Vuex)
is needed to activate Vuex for our application.
The initial state of the store is defined by the state object. To keep things simple we’re only defining one property count and set the initial value to 0. The state object is used to create the store instance by the method Vuex.Store and passing in an object containing state.
Now we’re able to inject the store into our Vue application instance. Open file main.js and adapt the code as follows:
import Vue from 'vue' import App from './App' import store from './store/store' Vue.config.productionTip = false new Vue({ el: '#app', store, template: '<App/>', components: { App } })
First you need to import store. Next, add store to the configuration object which is passed to the Vue constructor. By providing the store option to the root instance, the store will be injected into all child components of the root and will be available on them as this.$store.
Accessing State
Using the $store Object
Now, that the $store object is available in all components we’re able to use the following expression in one of our component templates, e.g. in Hello.vue:
{{ $store.state.count }}
This will insert the value of count (0) in the HTML output which is generated and displayed
Using Getters
Now you’ve learnt how to create a store, define the state and access state properties by using the $store object. The next step is to access state by adding Getters to the store. You can compare Getters to Computed Properties which are available on component level. For example we can use a Getter to evaluate if the value of count is even or odd by adding the following code to store.js:
const getters = { evenOrOdd: state => state.count % 2 === 0 ? 'even' : 'odd' }
To make sure that the defined Getter is part of the Store, we need to add this Getters to the store configuration object which is passed to the call of Vuex.Store at the end of the file:
export default new Vuex.Store({ state, getters })
To use the evenOrOdd Getter in our component we need to make the following change in our component implementation in file Hello.vue:
<script> import { mapGetters } from 'vuex' export default { name: 'hello', computed: mapGetters([ 'evenOrOdd' ]) } </script>
Notice, that we’re adding the mapGetters function from the vuex package first. Then we’re calling mapGetters, passing in as a parameter a array listing the Getters we would like to use and assign the return value to the computed property of the component configuration object.
Now we can make use of evenOrOdd by including it in the template like you can see in the following:
Counter: {{ $store.state.count }} times, count is {{ evenOrOdd }}.
If the value of count in the store is even it returns the string “even”. If the value is odd it returns the string “odd”.
Modifying State
synchronously By Using Mutations
The next step is to modify the state. To directly modify state properties Mutations are used. Mutations are passed the current state and an optional payload. Mutations must be synchronous. Let’s define two Mutations in file store.js to increment and decrement:
const mutations = { increment (state) { state.count++ }, decrement (state) { state.count-- } }
Again, add the mutations object to the object which is passed to Vuex.Store:
export default new Vuex.Store({ state, getters, mutations })
asynchronously By Using Actions
In many cases it’s not sufficient to modfiy the state with a Mutation synchronously. Instead you need to perform asynchonous operations to retrieve values from a backend (e.g. accesing a data base or a web service) and then updating the state with that new value. In that case we need to add Actions to our store, as you can see in the following code listing:
import Vuex from 'vuex' import Vue from 'vue' Vue.use(Vuex) const state = { count: 0 } const mutations = { increment (state) { state.count++ }, decrement (state) { state.count-- } } const actions = { increment: ({ commit }) => commit('increment'), decrement: ({ commit }) => commit('decrement'), incrementIfOdd ({ commit, state }) { if ((state.count + 1) % 2 === 0) { commit('increment') } }, incrementAsync ({ commit }) { return new Promise((resolve, reject) => { setTimeout(() => { commit('increment') resolve() }, 1000) }) } } const getters = { evenOrOdd: state => state.count % 2 === 0 ? 'even' : 'odd' } export default new Vuex.Store({ state, getters, actions, mutations })
Here you can see that the actions object is containing four functions:
- increment
- decrement
- incrementIfOdd
- incrementAsync
Each Action handler function can receive two parameters, a context object giving us access to a commit method and the current state and a optional payload object.
actions: { increment (context, payload) { ... } }
The second parameter payload is only need if you want to pass in further information, e.g. values used to set a new state. The context object gives you access to the commit method, so that you can commit Mutations like you can see in the following:
context.commit('increment')
In our example we’re using the ES6 object deconstruction and arrow function feature, so that the code can be rewritten to:
increment: ({ commit }) => commit('increment')
The incrementAsync Action function demonstrates how to execute asynchronous code as part of an Action function.
Now let’s see how we can apply the four action methods in the corresponding template:
<template> <div class="container"> <div class="row text-center"> <h3>Clicked: {{ $store.state.count }} times, count is {{ evenOrOdd }}.</h3> <button class="btn btn-success" @+</button> <button class="btn btn-danger" @-</button> <button class="btn" @Increment if odd</button> <button class="btn" @Increment async</button> </div> </div> </template> <script> import { mapGetters, mapActions } from 'vuex' export default { name: 'hello', computed: mapGetters([ 'evenOrOdd' ]), methods: mapActions([ 'increment', 'decrement', 'incrementIfOdd', 'incrementAsync' ]) } </script>
Here you can see that first we’re extending the import statement to also import the mapActions function. The return value of the mapActions call is assigned to the methods property of the component configuration object. We need to pass an array to mapActions containing strings with the names of the Actions we would like to make available to the component.
With this code in place we’re able to include four buttons in the template code and bind the click event of those buttons the the four Action functions. The result in the browser should now look like the following:
If you click on the plus and minus button you can immediately see that the output changes. The counter is updated and the output text contains the information if the new value is odd or even. If you click on button “Increment if odd” the counter is only incremented if the current counter value is odd. If you click on “Increment async” you’ll see that the counter is incremented with a delay of 1000 ms.
Summary
If your Vue application grows bigger and consists of multiple components which needs to share data, introducing a central state management might be the right approach for you project. By using the Vuex library it’s easy to implement central state management in your Vue app by introducing a central store in your application.
With this tutorial you’ve gained a basic overview about the centralized state management concept and you’ve learned how to apply Vuex in your application. In one of the next tutorials we’ll use that knowledge and dive deeper into that topic by implementing a real-world Vue.js application with Vuex. | https://codingthesmartway.com/vue-js-2-state-management-with-vuex-introduction/ | CC-MAIN-2020-40 | refinedweb | 1,811 | 62.58 |
[ ]
Mikhail Fursov commented on HARMONY-1802:
-----------------------------------------
AFAIK there is no problem with return types.
> [drlvm][jit] Jitrino.OPT does not handle unresolved method parameters properly
> ------------------------------------------------------------------------------
>
> Key: HARMONY-1802
> URL:
> Project: Harmony
> Issue Type: Bug
> Reporter: Mikhail Fursov
>
> Jitrino.OPT does not handle unresolved method parameters properly. Here is the testcase.
> compile this code:
> public class Test {
> public static void main(String[] args) {
> foo(null);
> }
> static void foo(X x) {}
> }
> class X {
> }
> delete X.class file and run the test with -Xem:opt cmdline option.
> The same problem occurs if class X is exception handler parameter.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
-
For more information on JIRA, see: | http://mail-archives.apache.org/mod_mbox/harmony-commits/200610.mbox/%3C17203239.1160480666469.JavaMail.root@brutus%3E | CC-MAIN-2016-26 | refinedweb | 120 | 59.09 |
rbb@covalent.net writes:
> Not on my linux box no. Hmmmm.....
>
> Ryan
>
> >...
further research:
my Linux box with these droppings: redhat 6.0
my Linux box without these droppings: mandrake 7.0
on both boxes, the generated configure is bad
echo $ac_n "checking for POLLIN in
#include <poll.h>
#include <sys/poll.h> ""... $ac_c" 1>&AC_FD_MSG
echo "configure:8758: checking for POLLIN in
#include <poll.h>
#include <sys/poll.h> " >&AC_FD_CC
if eval "test \"\${ac_cv_define_POLLIN+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
O.k.... On the box without the droppings, if I start bash via
/bin/sh, echo "gobble" 1>&GOBBLE won't create such droppings but if I
start it via /bin/bash it *will*. That bash is 2.03. The bash which
always creates droppings is 1.14.
This should explain why you don't get the droppings and I do.
Nothing (yet) explains why we have >&AC_FD_MSG in configure in the
first place :(
--
Jeff Trawick | trawick@ibm.net | PGP public key at web site:
Born in Roswell... married an alien... | http://mail-archives.apache.org/mod_mbox/httpd-dev/200009.mbox/%3Cm38zsbkopg.fsf@adsl-77-241-65.rdu.bellsouth.net%3E | CC-MAIN-2018-34 | refinedweb | 176 | 78.14 |
Seeking to bolster Flash and AIR (Adobe Integrated Runtime) application development, Adobe is working on "Gumbo," the next version of the Flex platform.
Adobe in blog entries and Web pages focused on improvements in the Gumbo open source SDK, which is due in the second half of 2009. Also planned is a version of the Flex framework geared toward form factors such as mobile devices.
The Gumbo SDK features three primary themes: Design in Mind, Developer Productivity, and Framework Evolution, according to Adobe presentations on the release.
"Design in Mind, in my mind, is probably our No. 1 focus for this release," said Matt Chotin, Flex SDK product manager at Adobe, in a July 2008 presentation on the Web.
"The biggest thing that you're going to see, I think, in the SDK itself is some of the new component and skinning architecture," said Chotin "It is a whole new architecture that really is meant to allow easy 'skin-ability' of components."
Plans also call for building out the MXML language to support more "tool-ability," Chotin said. MXML is the XML language used to lay out UI components for Flex applications.
Thermo, a planned Adobe tool for quickly building rich Internet applications, is serving as a big driver to making the SDK more tool-able, said Chotin. MXML improvements will make it easier to describe experience-oriented features such as states and transitions.
Also planned is a new MXML namespace and a file format called FXG, which is "about describing vector graphics in XML in a way that closely matches what Flash Player is capable of doing," said Chotin. Vector graphic information can be transferred between Thermo, Flex, and various tools.
With Gumbo, Adobe seeks to have designers more involved in building applications such as event-driven sites, item browsers, and product selectors. Gumbo will be merged with the Flex component model, which is called "Halo."
A lightweight framework anticipated in 2010 would support Flex on devices such as mobile units. Other framework improvements planned will support text features that are part of Flash Player 10. Developers will be able to make bidirectional layouts. Video improvement is planned also.
To improve developer productivity, Adobe with the Gumbo SDK is working on compiler performance and will add two-way data-binding and automation support for Flex in AIR and CSS (Cascading Style Sheets) improvements.
The Flex Builder IDE uses the Flex SDK to compile code. | http://www.infoworld.com/d/developer-world/adobe-readies-gumbo-upgrade-flex-086 | crawl-002 | refinedweb | 405 | 60.75 |
In today’s post we will try to build a Recurrent Neural Network with numpy, in order to get a better understanding of how recurrent algorithms are used in NLP.
The limits of my language mean the limits of my world.Ludwig Wittgenstein
Natural language processing is a branch of artificial intelligence that focuses on enabling computers to understand and manipulate human language.
It is fascinating to see how fast has natural language processing evolved during the last decade. As an example, the paragraph above in italic was written by GTP3, one of the most powerful language models nowadays. I just wrote the phrase “Natural language processing is” and the model returned the rest of the phrase.
But alongside evolution sometimes comes complexity and, similar to what we have seen in other posts, when using deep learning frameworks to build complex models sometimes it feels as if we were working with a black box.
So I thought that building a RNN from scratch could help us gain some intuition of how these complex models work.
Why a RNN from scratch?
RNN is one of the simplest algorithms used in NLP and once we have the intuition of how it works, it will be much easier for us to understand more complex models.
Furthermore, sometimes, instead of reading about it, building the model from scratch forces you to understand what is happening under the hood.
Our model
For our example, we will build a RNN that will try to create new (or real) names of people. In order to do so, we will build the typical many-to-many RNN. This is, given a set of \(n \) inputs, the model iterates for each one of them to compute the expected \(n \) outputs.
In our case, the input will be a name containing \(n\) letters and the model will recursively try to predict the next following letter for each letter in the word.
I once did a similar example in the DeepLearningAI deep learning course, but I never had the time to try and build one completely from scratch.
Give me the code!
Even though our class RNNModel will have other methods inside, in this post we will only go through the main ones. These are:
- Forward propagation.
- Loss calculation.
- Backward propagation.
- Clip method.
Some other methods have been implemented but are not shown in this post, such as:
- Random initialization of parameters of the model
- Optimization method.
Please note that the full model with the methods used can be found here.
class RNNModel: """ Recurrent neural network implementation. """ def __init__(self, input_dim, output_dim, hidden_dim): """ """ pass def forward(self, input_X): """ Computes the forward propagation of the RNN. """ pass def loss(self, Y): """ Computes the Loss of the RNN. """ pass def backward(self): """ Computes the backward propagation of the RNN. """ pass def clip(self, clip_value): """ Clips the gradients in order to avoid the problem of exploding gradient. """ pass def optimize(self): """ Updates the parameters of the model. """ pass
The forward propagation
The forward propagation of the RNN is really simple and can be resumed with the following formulas:
- Hidden state: $$ a_{t} = tanh(W_{a,x} * X + W_{a, a} * a_{t-1} + b_{a})
$$
- Y prediction: $$ y_{pred} = softmax(W_{y,a} * a_{t} + b_{y}) $$
In our example, for each epoch, we will iterate (with the same weights) over these two formulas for each letter in the word. The \(a\) denotes the hidden state, and \(a_{t-1}\) the hidden state of the previous cell. Note that the first \(a\), \(a_{0}\) will be set to 0.
def forward(self, input_X): """ Computes the forward propagation of the RNN. Parameters ---------- input_X : numpy.array or list List containing all the inputs that will be used to propagate along the RNN cell. Returns ------- y_preds : list List containing all the preditions for each input of the input_X list. """ self.input_X = input_X self.layers_tanh = [Tanh() for x in input_X] hidden = np.zeros((self.hidden_dim , 1)) self.hidden_list = [hidden] self.y_preds = [] for input_x, layer_tanh in zip(input_X, self.layers_tanh): input_tanh = np.dot(self.Wax, input_x) + np.dot(self.Waa, hidden) + self.b hidden = layer_tanh.forward(input_tanh) self.hidden_list.append(hidden) input_softmax = np.dot(self.Wya, hidden) + self.by y_pred = self.softmax.forward(input_softmax) self.y_preds.append(y_pred) return self.y_preds
Cross Entropy loss
Since we are doing a many-to-many algorithm, we will need to sum up all the losses obtained by each prediction (letter) made for the given word.
Following the example, for the word ‘Hello’ we will have an input 5 and an output of 5 letters as well, so we will have to sum up the losses obtained for the 5 letters predicted.
$$
l_{t}(y_{pred, t}, y_{t}) = -y_{t} * log(y_{pred, t}) – (1-y_{t}) * log(1 – y_{pred, t})
$$
$$
L(y_{pred}, y) = \sum_{i} l_{t}(y_{pred, t}, y_{t})
$$
class CrossEntropyLoss: """ Class that implements the Cross entropy loss function. Given a target math:`y` and an estimate math:`\hat{y}` the Cross Entropy loss can be written as: .. math:: \begin{aligned} l_{\hat{y}, class} = -\log\left(\frac{\exp(\hat{y_n}[class])}{\sum_j \exp(\hat{y_n}[j])}\right), \\ L(\hat{y}, y) = \frac{\sum^{N}_{i=1} l_{i, class[i]}}{\sum^{N}_{i=1} weight_{class[i]}}, \end{aligned} References ---------- .. [1] Wikipedia - Cross entropy: """ def __init__(self): self.type = 'CELoss' self.eps = 1e-15 def forward(self, Y_hat, Y): """ Computes the forward propagation. Parameters ---------- Y_hat : numpy.array Array containing the predictions. Y : numpy.array Array with the real labels. Returns ------- Numpy.arry containing the cost. """ self.Y = Y self.Y_hat = Y_hat _loss = - Y * np.log(self.Y_hat) loss = np.sum(_loss, axis=0).mean() return np.squeeze(loss) def backward(self): """ Computes the backward propagation. Returns ------- grad : numpy.array Array containg the gradients of the weights. """ grad = self.Y_hat - self.Y return grad
def loss(self, Y): """ Computes the Cross Entropy Loss for the predicted values. Parameters ---------- Y : numpy.array or list List containing the real labels to predict. Returns ------- cost : int Cost of the given model. """ self.Y = Y self.layers_loss = [CrossEntropyLoss() for y in self.Y] cost = 0 for y_pred, y, layer in zip(self.y_preds, self.Y, self.layers_loss): cost += layer.forward(y_pred, y) return cost
The backward propagation
Also known as backpropagation through time is always the most difficult part. Using the chain rule, the backward propagation of our model can be described with the following formulas:
Loss function derivative.
$$
\frac{\partial J}{\partial y} = (Y_{pred} – Y)
$$
Weights and bias derivative for the y_{pred}.
$$
\frac{\partial J}{\partial W_{y, a}} =
\frac{\partial y}{\partial W_{y, a}} *
\frac{\partial J}{\partial y} = a *
\frac{\partial J}{\partial y}
$$
$$
\frac{\partial J}{\partial b_{y}} = \frac{\partial J}{\partial y}
$$
Derivative of the hidden state.
$$
\frac{\partial J}{\partial a} =
\frac{\partial y}{\partial a} *
\frac{\partial J}{\partial y} = W_{y, a} *
\frac{\partial J}{\partial y} +
\frac{\partial J}{\partial a_{t+1}}
$$
$$
\frac{\partial J}{\partial tanh(x, a)} = (1 – a^{2}) *
\frac{\partial J}{\partial a}
$$
Gradients of the weights and bias to compute the hidden state.
$$
\frac{\partial J}{\partial W_{x, a}} =
X *
\frac{\partial J}{\partial tanh(x, a)}
$$
$$
\frac{\partial J}{\partial W_{a, a}} =
a_{t-1} *
\frac{\partial J}{\partial tanh(x, a)}
$$
def backward(self): """ Computes the backward propagation of the model. Defines and updates the gradients of the parameters to used in order to actulized the weights. """ gradients = self._define_gradients() self.dWax, self.dWaa, self.dWya, self.db, self.dby, dhidden_next = gradients for index, layer_loss in reversed(list(enumerate(self.layers_loss))): dy = layer_loss.backward() # hidden actual hidden = self.hidden_list[index + 1] hidden_prev = self.hidden_list[index] # gradients y self.dWya += np.dot(dy, hidden.T) self.dby += dy dhidden = np.dot(self.Wya.T, dy) + dhidden_next # gradients a dtanh = self.layers_tanh[index].backward(dhidden) self.db += dtanh self.dWax += np.dot(dtanh, self.input_X[index].T) self.dWaa += np.dot(dtanh, hidden_prev.T) dhidden_next = np.dot(self.Waa.T, dtanh)
After doing the backward propagation, we will need to clip the gradients in order to avoid the problem of exploding gradient.
def clip(self, clip_value): """ Clips the gradients in order to avoisd the problem of exploding gradient. Parameters ---------- clip_value : int Number that will be used to clip the gradients. """ for gradient in [self.dWax, self.dWaa, self.dWya, self.db, self.dby]: np.clip(gradient, -clip_value, clip_value, out=gradient)
Finally, we will only need to optimize the parameters using the stochastic gradient descent (SGD), similar to the previous post, to obtain the new weights and compute again all the steps.
Test our model
So, it’s time to check if our model works and can create new (or real) names!
The full code of the example can be found in this notebook.
To train our model we will be using the dataset person_names, which contains around 19.000 names.
person_names = open('person_names.txt', 'r').read() person_names= person_names.lower() characters = list(set(person_names)) character_to_index = {character:index for index,character in enumerate(sorted(characters))} index_to_character = {index:character for index,character in enumerate(sorted(characters))} with open("person_names.txt") as f: person_names = f.readlines() person_names = [name.lower().strip() for name in person_names] np.random.shuffle(person_names)
Note that since there are 26 words in the alphabet and we add the character ‘\n’ to denote the end of the word, our input dimension will have a dimension of \(N x 27\) where \(N\) are the number of letters in the word and 27 a one-hot encoded vector indicating the position of the letter in the alphabet. The same applies to the output dimension.
I have set our hidden state to have a dimension of \( 50×50 \)
num_epochs = 100001 input_dim = 27 output_dim = 27 hidden_dim = 50 # initialize and define the model hyperparamaters model = RNNModel(input_dim, output_dim, hidden_dim) optim = SGD(lr=0.01) costs = []
Train the model and generate some random names every 4.000 epochs.
# Training for epoch in range(num_epochs): # create the X inputs and Y labels index = epoch % len(person_names) X = [None] + [character_to_index[ch] for ch in person_names[index]] Y = X[1:] + [character_to_index["\n"]] # transform the input X and label Y into one hot enconding. X = one_hot_encoding(X, input_dim) Y = one_hot_encoding(Y, output_dim) # steps of the model model.forward(X) cost = model.loss(Y) model.backward() # clip gradients model.clip(clip_value=1) # optimize model.optimize(optim) if epoch % 10000 == 0: print ("Cost after iteration %d: %f" % (epoch, cost)) costs.append(cost) print('Names created:', '\n') for i in range(4): name = model.generate_names(index_to_character) print(name)
Cost after iteration 0: 22.388388 Names created: wiibjnaswxngbih msprglszcxepjjg ntlipdryxt minjhhsixfxkfo
Cost after iteration 40000: 16.226669 Names created: maryan mily seryna shaques
Not bad at all! The names that the model outputs after iteration 40.000 seem quite fine to me. As we can see, the model has improved the generation of names since its first iteration.
Conclusions
In today’s post, we have built a RNN many-to-many model from scratch and then tried to create new names. In future posts, we could try to create more complex models such as the LSTM.
I hope you enjoyed it! Thanks for reading and see you in the next post.
References
- Christopher Olah – Understanding LSTM Networks
- Michael Phi – Illustrated Guide to Recurrent Neural Networks: Understanding the Intuition
- Michael Phi – Illustrated Guide to Recurrent Neural Networks | https://quantdare.com/implementing-a-rnn-with-numpy/ | CC-MAIN-2022-40 | refinedweb | 1,904 | 50.12 |
In our Google Summer of Code project a part of our work is to bring knitting to the digital age. We is Kirstin Heidler and Nicco Kunzmann. Our knittingpattern library aims at being the exchange and conversion format between different types of knit work representations: hand knitting instructions, machine commands for different machines and SVG schemata.
The image above was generated by this Python code:
import knittingpattern, webbrowser example = knittingpattern.load_from().example("Cafe.json") webbrowser.open(example.to_svg(25).temporary_path(".svg"))
So far about the context. Now about the Quality tools we use:
Continuous integration
We use Travis CI [FOSSASIA] to upload packages of a specific git tag automatically. The Travis build runs under Python 3.3 to 3.5. It first builds the package and then installs it with its dependencies. To upload tags automatically, one can configure Travis, preferably with the command line interface, to save username and password for the Python Package Index (Pypi).[TravisDocs] Our process of releasing a new version is the following:
- Increase the version in the knitting pattern library and create a new pull request for it.
- Merge the pull request after the tests passed.
- Pull and create a new release with a git tag using
setup.py tag_and_deploy
Travis then builds the new tag and uploads it to Pypi.
With this we have a basic quality assurance. Pull-requests need to run all tests before they can be merge. Travis can be configured to automatically reject a request with errors.
Documentation Driven Development
As mentioned in a blog post, documentation-driven development was something worth to check out. In our case that means writing the documentation first, then the tests and then the code.
Writing the documentation first means thinking in the space of the mental model you have for the code. It defines the interfaces you would be happy to use. A lot of edge cases can be thought of at this point.
When writing the tests, they are often split up and do not represent the flow of thought any more that you had when thinking about your wishes. Tests can be seen as the glue between the code and the documentation. As it is with writing code to pass the tests, in the conversation between the tests and the documentation I find out some things I have forgotten.
When writing the code in a test-driven way, another conversation starts. I call implementing the tests conversation because the tests talk to the code that it should be different and the code tells the tests their inconsistencies like misspellings and bloated interfaces.
With writing documentation first, we have the chance to have two conversations about our code, in spoken language and in code. I like it when the code hears my wishes, so I prefer to talk a bit more.
Testing the Documentation
Our documentation is hosted on Read the Docs. It should have these properties:
- Every module is documented.
- Everything that is public is documented.
- The documentation is syntactically correct.
These are qualities that can be tested, so they are tested. The code can not be deployed if it does not meet these standards. We use Sphinx for building the docs. That makes it possible to tests these properties in this way:
- For every module there exists a .rst file which automatically documents the module with autodoc.
- A Sphinx build outputs a list of objects that should be covered by documentation but are not.
- Sphinx outputs warnings throughout the build.
testing out documentation allows us to have it in higher quality. Many more tests could be imagined, but the basic ones already help.
Code Coverage
It is possible to test your code coverage and see how well we do using Codeclimate.com. It gives us the files we need to work on when we want to improve the quality of the package.
Landscape
Landscape is also free for open source projects. It can give hints about where to improve next. Also it is possible to fail pull requests if the quality decreases. It shows code duplication and can run pylint. Currently, most of the style problems arise from undocumented tests.
Summary
When starting with the more strict quality assurance, the question arose if that would only slow us down. Now, we have learned to write properly styled pep8 code and begin to automatically do what pylint demands. High test-coverage allows us to change the underlying functionality without changing the interface and without fear we may break something irrecoverably. I feel like having a burden taken from me with all those free tools for open-source software that spare my time to set quality assurance up.
Future Work
In the future we like to also create a user interface. It is hard, sometimes, to test these. So, we plan not to put it into the package but build it on the package. | http://blog.fossasia.org/tag/ayab/page/2/ | CC-MAIN-2017-26 | refinedweb | 813 | 65.52 |
This says a lot about the intelligence of some of the folks on Slashdot. Are they having a joke? Perhaps. But cheering on a virus is kind of like cheering on a terrorist.
Via ExtremeTech.
This says a lot about the intelligence of some of the folks on Slashdot. Are they having a joke? Perhaps. But cheering on a virus is kind of like cheering on a terrorist.
Via ExtremeTech.
I think they "like" the fact that its running a DoS against. :/
Cheering on a virus is NOTHING like cheering on a terrorist (though I don’t agree with either) – I wish people would stop over-dramitising viruses, MyDoom has been caught by ALL commercial virus checkers for months, with all the viruses around you really have to be dumb to not have a decent virus checker installed.
OK, so viruses are inconvenient, they may even destroy data – but so far as I’m aware, no-one has been killed by MyDoom. I live in a country (the UK) where we had violent terrorism for 25 years (most people seem to forget this!), believe me I’d rather have people writing self replicating code than blowing up city centres.
Scott, fair point, perhaps my analogy is harsh, but I guess my point is, someone who writes and releases a virus is trying to cause destruction of property. Cheering that behaviour on is malfeasance.
Scott, so are you saying it’s okay to champion viruses and their creators? You condone this behaviour?
Cameron, did you read my comment…"though I don’t agree with either" – no I do not in any way believe what Virus creators do is right. It is rightly illegal and they should be punished – but to equate them with people who willingly and callously take the lives of others is an overreaction.As for destruciuon of property – again, who’s house has a virus destroyed, who’s children have they killed?
(pasted from:)
Another point I would add to my namespace collisions comment is "Who is the virus hitting and infecting? People who haven’t patched and run untrusted executibles despite countless warnings."
Computer Associates is giving away their antivirus/firewall solution for free (free one-year subscription, after which you’ll have to pay). I guess this will be a joint CA-Microsoft action, because it’s "Protect Your PC" all the way. So, if you know someone who doesn’t want to pay for his computer’s security, you can now tell them to have a look at. Spread the word and make the net a lot safer…
Scott,
Sorry, I must have missed your bracketed comment. And listen – I mostly agree with your comments that users only have themselves to blame if they get infected. God knows we have tried to make it as easy as humanly possible for users to stay virus free. However, if we are going to realize the vision of having non-technical people trust their PC to "just work" in the same way they trust the telephone to "just work", then we need to continue AS AN INDUSTRY to stamp this kind of irresponsible behaviour out. And I’m just annoyed that Slashdotters think it’s a joke. Okay, maybe they are all wannabe h4xorz,
Viruses DO destroy property. They destroy files. They cost money. If every PC user needs to spend $50 a year on a new piece of AV software to continue to fend off digital terrorists, and lets say there are 100 million PC users out there, then perpetrators are costing PC users $5 BILLION a year. Not to mention the cost to corporate. Money is property.
Tom,
the CA deal is interesting. That’s the AV software we use internally.
As a "slashdotter" I’ve got to ask: Did you or the ExtremeTech people actually READ the responses at /.?
The quoted three posts, the first two posts (the "funny" ones) and one other post, out of 847. If you get farther than 1/4 of the way down the posts (I’m reading at level 2 because I’ve got mod points. Gotta "Shout down" the losers), you’ll see that the posts quickly turn from "ha ha that’s funny that it’s SCO" to "Goddamit, who wrote this? I’m gonna kill them. I’m still get hits from Code Red in my server log. The last thing we need is another virus" and then to "This is a stupid idea and it makes Linux users look very, very bad."
You’ve got to admit this thread (), a take off of a Monty Python sketch, is classic.
" Back in my day, viruses came in via the boot-sector of floppy drive. You actually had to know fudge to write one.
You yung whipper-snapper virus writers and your MS holes got it way too easy."
Another poster at /. points out the obvious. How joking about this reflects badly on the entire Open Source community because the media will only report the negative.
Scott,
I don’t know about the ExtremeTech folks, but I went to /. myself to read the posts before I linked to the article. I only read the first level though, i hasve to admit. Good to see some /.’s balancing out the discussion.
Scott has some excellent rebuttals of my anti-/. virus rant. | https://blogs.msdn.microsoft.com/cameronreilly/2004/01/31/slashdotters-cheer-for-mydoom/ | CC-MAIN-2016-44 | refinedweb | 893 | 72.87 |
02-12-2011 11:48 AM - edited 02-12-2011 03:45 PM
i just started testing my display assets on the simulator (v 0.9.3) with discouraging results.
for portability / future-proofing purposes, my display assets are large vector (one or two bitmap) files which are scalled down proportionaly to match the height of the target device's screen.
when testing in ADL, these assets are anti-aliased and look as they should. however, when testing on the simulator the display assets look very jagged around the edges - even on vector assets! this is also also the case for assets that are not scalled.
i'm using the command line to package / install the application as i'm using Flash Professional CS5 (which contains the scalable vector assets in the library)
any ideas why this is happening?
--
EDIT: creating and embedding an assets.swf containing the vector sprites in Flash Builder also exhibits the same aliased results when debugging on the simulator.
02-12-2011 03:52 PM
Keep in mind the final simulator has a lot denser screen resolution than the simulator or the desktop, so you have to assume the anti-aliasing along the edges will be better.
02-12-2011 03:57 PM
i had assumed that at first, but then i noticed the icon for Browser as well as the text on the home screen and setting panel is perfectly smooth and crisp. therefore, i'm not sure that this aliasing problem will be any less visible on the device.
02-12-2011 04:05 PM
An image and the graphics drawing routines render differently. I have some graphics drawing that can easily be off a pixel and look like ***beep***. I recall that there is "sub-pixel" math that can be turned on since normal graphics is done at the integer level. I cant recall where I saw this. When I create PNG files, there is a world of difference between PNG-8 and PNG-24.
02-12-2011 04:35 PM - edited 02-12-2011 04:39 PM
hand coded graphics exhibit the same aliasing problem (noticable on the white stroke):
package { //Imports import flash.display.GradientType; import flash.display.Sprite; import flash.geom.Matrix; //Class [SWF(height="600", width="1024", frameRate="30", backgroundColor="#444444")] public class PlayBookTest extends Sprite { //Constructor public function PlayBookTest() { init(); } //Initialize private function init():void { var sp:Sprite = new Sprite(); var matrix:Matrix = new Matrix(); matrix.createGradientBox(200, 200, Math.PI / 2.95); sp.graphics.beginGradientFill(GradientType.LINEAR, [0xFF0000, 0xFFFF00, 0x0000FF], [1.0, 1.0, 1.0], [0, 95, 225], matrix); sp.graphics.lineStyle(2, 0xFFFFFF); sp.graphics.lineTo(0, 0); sp.graphics.curveTo(20, 100, 200, 10); sp.graphics.curveTo(100, 100, 125, 200); sp.graphics.curveTo(0, 200, 0, 0); sp.x = stage.stageWidth / 2 - sp.width / 2; sp.y = stage.stageHeight / 2 - sp.height / 2; addChild(sp); } } }
02-12-2011 06:12 PM
02-12-2011 08:52 PM
it would be nice to have confirmation from RIM on this, eventhough it wouldn't really make a difference at this stage of the game.
fingers crossed that it's an issue with pixel density.
02-15-2011 10:06 AM - edited 02-15-2011 10:15 AM
I just wanted to add a few images to back up what I am seeing in my second application to better illustrate my situation, and help to backup TheDarkIn1978's claim.
I decided to just use attachments as they show up quicker ( I think ) and also they show at 100%.
See below for attachments if interested. Exact same code used to create both graphics, the only difference is the data points. If need be I can certainly take the time to make the logbook entries exactly the same for better comparison.
02-15-2011 10:29 AM
I see this too on much simpler geometry. A single rectangle or round rectangle will be off by a pixel and the anti-alias on the simulator just **beep**. I am just hoping that the final device has a lot better rendering tailored to its resolution than the simulator does.
02-15-2011 10:36 AM
I'm now thinking this is the same underyling cause for the asymmtery that led me to add "+2" and "-2" compensating factors for several of control points in my bezier curves in the corners of the "popover" box code. I never actually tried it on the desktop, but on the simulator it certainly looked bad without that.
I think perhaps the implementation of OpenGL that is being used in the simulator, which is x86-based, is turning out to have problems that, as John said, we can hope will not be on the ARM-based device.
Unfortunately it may well mean we can't rely on what we see on the simulator to tell us reliably how it will look on the final device, which poses a problem for all these sim-based early apps.
RIM: now would be a really good time to have somebody get a bit more involved in this forum for a moment, as in someone with access to the actual device, who could test out some sample code or in some other way confirm some of this speculation. Do we have to test our graphics on the desktop and go by how it looks there, or what? | http://supportforums.blackberry.com/t5/Adobe-AIR-Development/Assets-Without-Anti-Aliasing-on-Simulator-EDITED/m-p/791091 | CC-MAIN-2013-48 | refinedweb | 899 | 63.19 |
Skill settings provide the ability for users to configure a Skill using a web-based interface. This is often used to:
Change default behaviors - such as the sound used for users alarms.
Authenticate with external services - such as Spotify
Enter longer data as text rather than by voice - such as the IP address of the users Home Assistant server.
Skill settings are completely optional.
To define our Skills settings we use a
settingsmeta.json or
settingsmeta.yaml file. This file must be in the root directory of the Skill and must follow a specific structure.
To see it in action, lets look at a simple example from the Mycroft Date-Time Skill. First using the JSON syntax as a
settingsmeta.json file:
{"skillMetadata": {"sections": [{"name": "Display","fields": [{"name": "show_time","type": "checkbox","label": "Show digital clock when idle","value": "false"}]}]}}
Now, here is the same settings, as it would be defined with YAML in a
settingsmeta.yaml file:
skillMetadata:sections:- name: Displayfields:- name: show_timetype: checkboxlabel: Show digital clock when idlevalue: "false"
Notice that the value of
false is surrounded by "quotation marks". This is because Mycroft expects a string of
"true" or
"false" rather than a Boolean.
Both of these files would result in the same settings block.
It is up to your personal preference which syntax you choose.
Whilst the syntax differs, the structure of these two filetypes is the same. This starts at the top level of the file by defining a
skillMetadata object. This object must contain one or more
sections elements.
Each section represents a group of settings that logically sit together. This enables us to display the settings more clearly in the web interface for users.
In the simple example above we have just one section. However the Spotify Skill settings contains two sections. The first is for Spotify Account authentication, and the second section contains settings to define your default playback device.
Each section must contain a
name attribute that is used as the heading for that section, and an Array of
fields.
Each section has one or more
fields. Each field is a setting available to the user. Each field takes four properties:
name (String)
The
name of the
field is used by the Skill to get and set the value of the
field. It will not usually be displayed to the user, unless the
label property has not been set.
type (Enum)
The data type of this field. The supported types are:
text: any kind of text
checkbox: boolean, True or False
number: text validated as a number
password: text hidden from view by default
select: a drop-down menu of options
label: special field to display text for information purposes only. No name or value is required for a
label field.
label (String)
The text to be displayed above the setting field.
value (String)
The initial value of the field.
Examples for each type of field are provided in JSON and YAML at the end of this page.
Once settings have been defined using a
settingsmeta file, they will be presented to the user on their personal Skill Settings page.
When settings are fetched from the Mycroft server, they are saved into a
settings.json file, also in the Skills root directory. This file is automatically created when a Skill is loaded even if the Skill does not have any settings. Your Skill then accesses the settings from this file.
Skill settings are available on the MycroftSkill class and inherit from a Python Dict. This means that you can use it just like you would any other Python dictionary.
To access the
show_time variable from our example above we would use the
Dict.get method:
self.settings.get('show_time')
If the setting we are trying to access is not available, the
get method will return
None. Instead of assigning this to a variable and then testing for
None, we can provide a default value as the second argument to the
get method.
self.settings.get('show_time', False)
In this example, if the settings have not been received, or the
show_time setting has not been assigned, it will return the default value
False.
A few warnings
We recommend using the
Dict.get method above rather than accessing the setting directly with:
self.settings['show_time']
Directly referencing the value may throw a KeyError if the setting has not yet been fetched from the server.
It is also important to note that the
settings dictionary will not be available in your Skills
__init__ method as this is setting up your Skills Class. You should instead use an
initialize method which is called after the Skill is fully constructed and registered with the system. More detail is available at:
Each Mycroft device will check for updates to a users settings regularly, and write these to the Skills
settings.json. To perform some action when settings are updated, you can register a callback function in your Skill.
def initialize(self):self.settings_change_callback = self.on_settings_changedself.on_settings_changed()def on_settings_changed(self):show_time = self.settings.get('show_time', False)self.trigger_time_display(show_time)
In the example above, we have registered the
on_settings_changed method to be our callback function. We have then immediately called the method to perform the relevant actions when the Skill is being initialized even though the Skills settings have not changed.
In the
on_settings_changed method we have assigned the value of the
show_time setting to a local variable. Then we have passed it as an argument to another method in our Skill that will trigger the display of the time based on its value.
Your Skill can reassign a setting locally, however these values remain local and cannot be pushed to the server. To do this we assign a value like you would with any other dictionary key.
self.settings['show_time'] = True
The new value for the
show_time setting will persist until a new setting is assigned locally by the Skill, or remotely by the user clicking
save on the web view.
{"skillMetadata": {"sections": [{"name": "Label Field Example","fields": [{"type": "label","label": "This is descriptive text."}]}]}}
skillMetadata:sections:- name: Label Field Examplefields:- type: labellabel: This is descriptive text.
{"skillMetadata": {"sections": [{"name": "Text Field Example","fields": [{"name": "my_string","type": "text","label": "Enter any text","value": ""}]}]}}
skillMetadata:sections:- name: Text Field Examplefields:- name: my_stringtype: textlabel: Enter any textvalue:
{"skillMetadata": {"sections": [{"name": "Email Field Example","fields": [{"name": "my_email_address","type": "email","label": "Enter your email address","value": ""}]}]}}
skillMetadata:sections:- name: Email Field Examplefields:- name: my_email_addresstype: emaillabel: Enter your email addressvalue:
{"skillMetadata": {"sections": [{"name": "Checkbox Field Example","fields": [{"name": "my_boolean","type": "checkbox","label": "This is an example checkbox. It creates a Boolean value.","value": "false"}]}]}}
skillMetadata:sections:- name: Checkbox Field Examplefields:- name: my_booleantype: checkboxlabel: This is an example checkbox. It creates a Boolean value.value: "false"
{"skillMetadata": {"sections": [{"name": "Number Field Example","fields": [{"name": "my_number","type": "number","label": "Enter any number","value": "7"}]}]}}
skillMetadata:sections:- name: Number Field Examplefields:- name: my_numbertype: numberlabel: Enter any numbervalue: 7
{"skillMetadata": {"sections": [{"name": "Password Field Example","fields": [{"name": "my_password","type": "password","label": "Enter your password","value": ""}]}]}}
skillMetadata:sections:- name: Password Field Examplefields:- name: my_passwordtype: passwordlabel: Enter your passwordvalue:
{"skillMetadata": {"sections": [{"name": "Select Field Example","fields": [{"name": "my_selected_option","type": "select","label": "Select an option","options": "Option 1|option_one;Option 2|option_two;Option 3|option_three","value": "option_one"}]}]}}
skillMetadata:sections:- name: Select Field Examplefields:- name: my_selected_optiontype: selectlabel: Select an optionoptions: Option 1|option_one;Option 2|option_two;Option 3|option_threevalue: option_one | https://mycroft-ai.gitbook.io/docs/skill-development/skill-structure/skill-settings | CC-MAIN-2020-24 | refinedweb | 1,228 | 54.12 |
I took up C#/.NET programming a few years ago, and the learning curve was not too terribly rough given my experience with C, C++ and (a little bit) Java. But as I immerse myself in a larger project, I keep finding things that I like about this language.
From time to time I'll touch on some of these features here, mainly for experienced developers who may not have visited C# yet. Today I'm writing about properties.
In C++ or Java, one creates an object with member fields and methods, and it's generally considered poor object-oriented form to expose the fields directly to users of the object (i.e., they should be private or protected). The better mechanism is to create get/set methods that allow manipulation of these private fields, and they can enforce restrictions on the variables and insure that internal state is consistent.
Delphi, the Pascal derivative, supported a feature known as Properties, which allowed an object's method to create get/set methods that look exactly to the callers like regular fields in an object - it was just the best of both worlds. Since the author of Delphi also created C#, it should be no surprise that this useful feature has made it into his new creation.
Properties allow creation of code blocks associated with explicit get and set fragments, and the system calls them as appropriate when used those contexts.
A contrived example lifted from the Microsoft knowledge base:
public class TimePeriod { public double Seconds; // REAL FIELD public double Hours // PROPERTY { get { return Seconds / 3600; } set { Seconds = value * 3600; } } } ... TimePeriod t = new TimePeriod(); t.Seconds = 60; // sets the real field Console.WriteLine("Time: {0} Hours or {1} Seconds", t.Hours, t.Seconds); t.Hours = 24; // sets the property Console.WriteLine("Time: {0} Hours or {1} Seconds", t.Hours, t.Seconds);
Here, setting Hours is done explicitly with the real underlying field, but Seconds are computed with the get fragment. Then, in the next step when t.Seconds are set — as if it were a real field — the computation is done by the set fragment to modify the underlying t.Hours field.
We certainly could have defined explicit get/set functions to do this:
public class TimePeriod { public double Seconds; public double getHours() { return Seconds / 3600; } public void setHours(double h) { Seconds = h * 3600; } } ... TimePeriod t = new TimePeriod(); t.Seconds = 60; Console.WriteLine("Time: {0} Hours or {1} Seconds", t.getHours(), t.Seconds); t.setHours(24); Console.WriteLine("Time: {0} Hours or {1} Seconds", t.getHours(), t.Seconds);
... but this treats Seconds and Hours differently when they don't need to be; using a property obviates the need to use unnatural setHours/getHours mechanisms when they can simply be treated as a regular field.
Properties can be effectively readonly by simply omitting the set part:
public class ShoppingItem { public double price; public int quantity; public double total { get { return price * quantity; } // no set property! } }
Here, total computes (item x quantity) to get the total, but there's simply no way to set that value. As before, one could have written this as a simple function public double total(), but once you've started using properties, it gets pretty attractive.
In many cases all you really want to do is provide a simple wrapper to underlying fields, without any validation checks or computations - this leaves the door open to adding those checks later as needed:
public class Foo { // tedious private int _something; public int something { get { return _something; } set { _something = value; } } ... others added here }
Most will say that this seems tedious, and having to write all this just to add a new fields is not that better than explicit getSomething/setSomething methods. But C# 3.0 provides a shortcut to this very case:
public class Foo { public int something { get; set; } // easy business ... others added here }
Because get and set are provided without bodies, the runtime simply creates an internal variable that it operates on with the obvious behavior. If something ever needs more definition, one can include the body to get or set without changing any of the calling code.
This is so easy to use, and so flexible when you do decide to add logic later, that it becomes almost habit to use properties for nearly everything public.
Properties can be public, private, or any other access specifier, and the get/set can have separate access classes. This example shows the property as a whole being public (which applies to get), but the more restrictive protected specifier for the set limits setting to derived classes only:
public class Foo { // only derived classes public int something { /* public */ get; protected set; } ... others added here }
Properties can be part of interfaces, they can specifi get/set parts separately (i.e, one interface can require public int foo { get; } while another can require public int foo { set; }, and a single implementation of get/set will satisfy them both.
It does not take long at all to really get to love properties and wish they were available in C++. | http://blog.unixwiz.net/2009/05/neat-c-features-properties.html | CC-MAIN-2014-42 | refinedweb | 843 | 51.68 |
Opened 15 years ago
Closed 11 years ago
Last modified 11 years ago
#4717 closed defect (fixed)
wrong table cell width with multibyte in ticket notify
Description
Expected:
Priority: major | Component: Others Keywords: tester xxxxxxxxxxxxx | Username: abc
Unxpected:
Priority: major | Component: Others Keywords: tester xxxxxxxxxxxxx | Username: abc
where xxxxxxxxxxxxx is 7 Chinese characters, in 14 'w' width
Attachments (5)
Change History (24)
comment:1 by , 15 years ago
comment:2 by , 15 years ago
i'm sure using fixed-width font, and each Chinese character is in the same width as 2 ascii, which IS expected, even u use fixed-width font in html. i agree that using html table can solve the problem, because browser calc the width correctly, but not trac. that's why i ask tach to fix itself, calc the text width, not character count (count of code point)
if u know php, there is mb_strwidth to do the job.
i'm not familar with python, but it seems there's:
east_asian_width( unichr) Returns the east asian width assigned to the Unicode character unichr as string. New in version 2.4.
One shall never suppose 1 Chinese char is same with as 1 ascii char, in fixed-width font.
comment:3 by , 15 years ago
east_asian_width(unichr)- New in version 2.4
Maybe we can bump the Python requirement in the next version of Trac?
(btw, mgood,
tee from itertools is also new in 2.4)
follow-up: 5 comment:4 by , 13 years ago
Note for self: reuse this code
from unicodedata import east_asian_width as eaw _colwidth = lambda s: sum([eaw(c) in 'WF' and 2 or 1 for c in s])
(from Shun-ichi Goto on Mercurial-devel, used with permission)
where xxxxxxxxxxxxx is 7 Chinese characters, in 14 'w' width
maybe a real example would help…
comment:5 by , 13 years ago
where xxxxxxxxxxxxx is 7 Chinese characters, in 14 'w' width
maybe a real example would help…
For example in Japanese, the text "日本語" (means "Japanese") has 3 characters and occupies 6 column width.
>>> len(u'日本語') 3 >>> _colwidth(u'日本語') 6
Expected (left:
Priority: major | Component: Others Keywords: tester 日本語 | Username: abc
Unwanted (extra 3 spaces):
Priority: major | Component: Others Keywords: tester 日本語 | Username: abc
follow-up: 7 comment:6 by , 13 years ago
comment:7 by , 13 years ago
Note that it doesn't look like browsers are respecting this 3 asian characters → 6 column width convention, at least when using the default fixed font, as can be seen in the above example.
I guess it is issue of renderer of application on using multiple fonts (for ASCII and Japanese). For example, if you use MSゴシック (msgothic) font on windows, you will see good looking because it is a fixed-width font having both ASCII and Japanese glyphs.
comment:8 by , 12 years ago
I created a patch 4717.diff for the issue using
unicodedata.east_asian_width.
New
[notification] ambiguous_char_width option is like ambiwidth option of Vim. CJK (Chinese, Japanese and Korean) users need this option and specify 'double'. Default of the option is 'single', the most users don't need to specify the option.
If you want to know about Ambiguous Characters, visit.
Trac 0.12dev-r9679 with the patch:
comment:9 by , 12 years ago
Thanks for the patch, it looks good except for a few details:
from unicodedata import east_asian_widthshould be among the first block of imports, as it's a module coming from stock Python
- I didn't count, but it looks like you have some lines > 79 (single width ;-) ) chars; please check our TracDev/CodingStyle
Finally, I think the setting makes sense in a locally deployed Trac instance, where most users are either CJK ones or not. But ultimately this should become a user setting, in the notification preferences (#4056).
follow-up: 12 comment:10 by , 11 years ago
comment:11 by , 11 years ago
by , 11 years ago
Refreshed t4717.diff to [10051/branches/0.12-stable]
comment:12 by , 11 years ago
comment:13 by , 11 years ago
per cboos' request in ticket:2378#comment:15, I reviewed and tested attachment:t4717-using-east-asian-width-r10051.diff. The patch produced no regressions in my testing and the code changes looked fine. I didn't test with any locales other than "en_US.UTF-8".
Nice touch incorporating the obfuscated email length in the table width calculations!
comment:14 by , 11 years ago
follow-up: 18 comment:15 by , 11 years ago
comment:16 by , 11 years ago
would be good to have a "Since 0.12.2" note in the doc(string).
comment:17 by , 11 years ago
by , 11 years ago
comment:18 by , 11 years ago
A unit-test would have been nice, feel free to contribute one later, Jun ;-)
I create t4717-unittest.diff for #4717 and #9494. Please apply if you can :)
So, you're saying that the characters in question are displayed in a font such that each character is wider than an ascii character. For plaintext mail formatting we expect the emails to be displayed in a fixed-width font so that all characters are the same width. If you can, configure your mail client to use a font where the characters will all be the same width. If you can't do that, I'm afraid there's no way to work around that for the plaintext mails. HTML email formatting has been requested, and would enable better formatting with variable-width fonts. See #2625. | https://trac.edgewall.org/ticket/4717?cversion=0&cnum_hist=17 | CC-MAIN-2021-49 | refinedweb | 918 | 64.75 |
I got the above error message while doing some random tests on my current Flex application. This always seemed to be happening under the following scenario... a DataGrid was on the screen, the grid was binded to a collection (myVosArrayCollection). One of the gird columns data fields was pointing to a nested value (myVO.field.child) :
<mx:DataGridColumn dataProvider="{myVosArrayCollection}" dataField="field.child".../>
It seems like Flex has a problem dealing with nested objects for dataGrid column dataField. My solution is adding a wrapper getter on myVO.field.child , for me this is only natural as I'm using a two level VOs hierarchy exactly for these sort of scenarios, the BaseVO and the VO it self (but that's something I'll cover on a different post). MyVo now have a new getter:
public class MyVO
{
private var field:Object;
public function get fieldChild():Object
{
return field.child;
}
}
my DataGrid now has the following setup:
This solved the issue for me.This solved the issue for me.
<mx:DataGridColumn dataProvider="{myVosArrayCollection}" dataField="fieldChild".../>
4 comments:
see another solution
Daniel, this is interesting, thanks. As I mentioned on the post above, I use a two levels VO concept which I'm hoping to discuss in a post some time soon, so for me the solution I showed is ideal.
Really great post .. It helped me alot. Thanks :)
Thanks Lior Boord. it's a good trick :) | http://www.flexonjava.net/2010/09/datagrid-error-find-criteria-must.html | CC-MAIN-2017-13 | refinedweb | 235 | 59.4 |
Are you sure?
This action might not be possible to undo. Are you sure you want to continue?
JBL 130, no. 2 (2011): 227–246
Sexual Desire? Eve, Genesis 3:16, and hqw#t
joel n. lohr
joel.lohr@twu.ca Trinity Western University, Langley, BC V2Y 1Y1, Canada
Yhwh Elohim says to the woman, “I shall multiply your suffering and your . . . pregnancies; with pain you shall give birth to sons; and your desire shall be unto your husband, and he shall rule over you” (3.16). Any interpretation of this utterance—as a curse, aetiological statement of fact, blessing or otherwise—is largely dependent on the reader’s gender position and may vary considerably.1
Thus states Athalya Brenner in her important monograph The Intercourse of Knowledge. Those who have spent any time in the literature surrounding the interpretation of this verse will probably only affirm Brenner’s dictum. In fact, some may be inclined to suggest that she is given to understatement. Her words could give the impression that readings of this verse “may vary,” when in fact they regularly do much more—at times they clearly oppose or contradict each other. There is also a risk in saying too little in speaking of one’s “gender position.” Clearly there are a variety of factors in play, not the least of which is one’s religious or theological persuasions, or one’s place in history, society, and culture. All of this, to be sure, contributes to one’s “gender position,” but we need to be clear. The effects of one’s wider presuppositions are truly far-reaching and profound in reading this verse. For some, Gen 3:16 is a problem not only for faith communities that hold the Bible as Scripture but also for the larger world and its social order. Given the Bible’s influence in and on various societies, the potential for this verse to be used for oppressive means should not be underestimated. Many see here the institution of
I am grateful to Dirk Büchner, Joel Kaminsky, Walter Moberly, and Christopher Seitz for their comments on an earlier draft of this article. A shorter version of it was presented at the Canadian Society of Biblical Studies Annual Meeting in Ottawa, Ontario (May 26, 2009). 1 Athalya Brenner, The Intercourse of Knowledge: On Gendering Desire and ‘Sexuality’ in the Hebrew Bible (Biblical Interpretation Series 26; Leiden: Brill, 1997), 53.
227
Mutuality is replaced by rule. .” is not the primary issue regarding the institution of patriarchy. the existence of profoundly opposed readings regarding it. the rabbis.” something he claims will “sometimes make [women] submit to quite unreasonable male demands. Biddle. Survey of Recent Interpretations: hqw#t Perhaps the most common way of understanding the term hqw#t is simply through the word “desire”—often taken as sensual. For example. Waco: Word. That is. 1930). Genesis (1901. Prior to this overview. Macon. as announced in Genesis 3:16. All of this is with a view toward understanding the meaning of hqw#t for both translation and interpretational purposes. Patriarchy is inaugurated. 4 Gunkel. I am principally concerned to provide an overview of how this verse—particularly the third line and the term hqw#t—has been translated and interpreted in antiquity. calls this a “sexual appetite.”2 But perhaps the term hqw#t in Gen 3:16. 2 (2011) patriarchy. though he agrees that the verse refers to a sexual desire. uses Bird.”4 Everett Fox. especially regarding the term hqw#t. I do this first to highlight the remarkable confusion there is surrounding the term and. it is also clear that this verse cannot be properly understood outside of the larger context of the Eden story and especially the deity’s other pronouncements upon the man and the serpent. GA: Mercer University Press. no.”3 Hermann Gunkel. that the two ideas are intricately related. and the fathers.228 Journal of Biblical Literature 130. all four lines of this verse are important and should be understood together. . 1987). In this article. Wenham. Edinburgh: T&T Clark. it instead introduces the clause that makes this clear.” is really the crux. or sexual. something he calls an “ardent desire. Mark E. in his translation of the Torah. however. Phyllis Bird’s words might be taken as representative: “A hierarchy of order is introduced into the relationship of the primal pair. Genesis 1–15 (WBC 1. “Bone of My Bone and Flesh of My Flesh. Gordon J. The rule of man over the woman. I examine instances of the term in the Dead Sea Scrolls and then make suggestions on how we might best translate and understand the term in the light of ancient practice. Wenham. 21. A Critical and Exegetical Commentary on Genesis (2nd ed. I briefly survey some of the different readings this verse has brought about in the recent past. desire. the immediately following line. is the Bible’s first statement of hierarchy within the species. “and he will rule over you. in his Genesis commentary. at times. Skinner. It is clear. Mercer Library of Biblical Studies. 3 2 . 82–83. often translated as “desire. I. in his commentary on the verse. however. ICC. trans. .” ThTo 50 (1994): 527. 1997). Following my survey of the history of reception. 81.” an idea with which John Skinner does not concur. refers to the woman here as having “a stronger libido than the man. In fact..
Deuteronomy. It includes the attraction that woman experiences for man which she cannot root from her nature. London: Methuen. Some are not even clear that the term indicates desire.” This desire for sexual intimacy. ” 9 Driver. Leviticus. 27. Fretheim. 11 Bledstein. suggests that we are here dealing not so much with desire as with “dependency. It is not merely sexual yearning. which carries the sense of being desirable. 112. he continues. WC. Driver. even to the point of nymphomania. 6 Lerner. suggests that hqw#t must be understood in the larger context of the man and the woman losing the original union and equal bond found in the creation stories of Genesis 1 and 2.8 This is but a small sampling of the literature. 1:172. 1978). She bases this on a potential semantic link to the Akkadian term kuzbu..” According to him. this dependency shows itself as a woman’s need for “cohabitation. Waltham. in her book God and the Rhetoric of Sexuality.10 In a rather different reading. feminists may seek to banish it. Eternally Eve: Images of Eve in the Hebrew Bible. Sheffield: Sheffield Academic Press.. . in the New Interpreter’s Bible. comes despite the potential for resultant pains of childbirth. 23.” That is. For Trible. S. Philadelphia: Fortress. 1942). 1905). It is a just penalty. in her in-depth and astute Jewish feminist reading of Eve. Numbers. 49. Commentary. 2007).” but states: This yearning is morbid. “Are Women Cursed in Genesis 3.16?” in A Feminist Companion to Genesis (ed. R. Genesis 3:16. and Notes (Schocken Bible 1. and Reflections. 7 Leupold. . Midrash. . “The Book of Genesis: Introduction. Exposition of Genesis (2 vols. or having allure. 1993). Athalya Brenner.Lohr: Sexual Desire? Eve. Adrian Janis Bledstein suggests that hqw#t should be understood not as desire or attraction to something but rather as “attractiveness. finds a continual attraction for him to be her unavoidable lot.”6 Perhaps the most extreme view here comes from the conservative Christian commentator Herbert C. NIB 1:363. and hqw#t 229 the term “lust. She who sought to strive apart from man . Fox uses the term in both Gen 3:16 and 4:7. Grand Rapids: Baker. 1995). calls this an “apparently unbridled sexual desire. Exodus. and not all interpreters agree that we are dealing with desire of a sexual kind.” but he provides no explanation for this decision in his notes. but it persists in cropping out . we might note the idea of Terence E.”9 Phyllis Trible.11 Carl Friedrich 5 Fox. 8 Fretheim. . MA: Brandeis University Press. . the woman will be “powerfully attractive” to her husband yet he can/will rule over her. 128. God and the Rhetoric of Sexuality (OBT 2. Leupold. He translates the term hqw#t as “yearning. . in his classic commentary on Genesis. Commentary. hqw#t comes to symbolize that for which the woman longs but which is now lost: the original unity and equality of male and female. The Book of Genesis: With Introduction and Notes (4th ed.5 Anne Lapidus Lerner. a longing for “sexual intimacy. 10 Trible.7 To contrast this extreme view. FCB 2. . There he refers to the term in Gen 3:16 simply as a type of longing. A New Translation with Introductions. and Modern Jewish Poetry (HBI Series on Jewish Women. New York: Schocken. . 142–45. The Five Books of Moses: Genesis.
He states: It is a mistake to believe that the relation of woman to man is [here] changed (from 2. nothing at all has really changed in the Gen 3:16 pronouncement made to Eve. Nothing would have changed had she not eaten the fruit. Israel Abrahams. should be the leader. compare Walter C. In Gen 4:7 it is used to describe sin (or perhaps Abel). 2007). James Martin. ready to pounce on Cain. Ernest I. we can see that a plethora of interpretations surrounds this term and the sampling offered here is just a smattering of more recent commentaries and studies. The First Book of the Bible: Genesis (trans. 14 Cassuto. even in the garden of Eden she would have given birth in pain and would have been subordinate to man. Does the dominating position of man contradict her position as helper? Naturally the stronger. . is counseled that he can/may/must/shall “master” it. the protector. it is worth noting how and where the term hqw#t features in the masoretic tradition. to examine how this term has been used in the ancient versions and translations. . they instead specify that it indicates a constant “seeking” of something.12 Lastly. how we translate this term in 3:16 will undoubtedly have implications for our understanding of the enigmatic Gen 4:7. augmented ed..14 In Canticles. Cain. who calls it “Der dunkelste Vers .. 1:103.20). in Gen 4:7. The Pentateuch (trans. In fact. 13 Jacob. and then in the interpretations of the rabbis and the church fathers.” it is nevertheless nothing new.. He states that. A Commentary on the Book of Genesis (trans. German original. no. We turn. Grand Rapids: Eerdmans.” Though this term is perhaps seemingly close to sexual desire.. something said to be lying in wait. hqw#t is used in a setting where the female 12 Keil and Delitzsch. Jerusalem: Magnes. . although the woman feels “‘irresistibly’ attracted to man. Jersey City: Ktav. 2 (2011) Keil and Franz Delitzsch also resist the word “desire” and instead opt for the idea of a “violent craving. 30. the same verb (l#m) used of the man concerning the woman in 3:16. Indeed. not necessarily in the sexual realm. der Genesis” . Compare Otto Procksch. however. . Jacob and Walter Jacob. Toward Old Testament Ethics (Grand Rapids: Zondervan. 1861–70). 1972). 1973. II. . 2 vols. As the parallels between these two passages are clear. and in Cant 7:10 [MT 11]. 3 vols.230 Journal of Biblical Literature 130. the term appears in only three places: here (Gen 3:16). then. Versions and Translations The Masoretic Text To begin. 204–5. 1:208. a verse that Umberto Cassuto probably rightly called “one of the most difficult and obscure” sentences in the Bible. As is well known.13 From all of the above. Kaiser Jr. 1983). things become more complex as we venture further into history. while discussing various interpretations. it is worth noting the reading of Benno Jacob.
1 Sam 7:17. for with longing you longed [ἐπιθυµίᾳ γὰρ ἐπεθύµησας.” consult LXX Deut 22:1. as well as the definitions in LSJ.” 486 n. in Gen 31:30.” or “inclination”).” CBQ 71 (2009): 485–96. rev. 62).”18 Given the evidence. a term that usually indicates a “turning” or “return. Leipzig: Deichert. Louvain: Peeters. and K. Contrast Greek-English Lexicon of the Septuagint (ed. 31:18. Instead. 6:19. 18 Or at times. as we might expect. and BDAG.15 Ἐπιθυµία (from ἐπιθυµέω) carries the sense of “desire” or “craving. stating that she belongs to him and that his hqw#t is for her.. Lust. 2007).” Note LXX Jer 8:5. the translator chose not to use ἐπιθυµία for hqw#t. and the New Testament. KAT 1. 47). 33:11. Greek Versions The LXX provides our first example of translational difficulty. “So now you have gone. LXX Canticles translates hqw#t in a similar fashion. Space does not permit a full discussion of the translation of this verse. it means “conversion. a term that Symmachus uses in his translation of Gen 3:16 and 4:7. [But] why did you steal my gods?”16 Alternatively. 8:5. Jer 5:6. 18:12. E. Mic 2:12. Albert Pietersma and Benjamin G. a word that also carries the sense of “return. Laban questions Jacob after his abrupt departure. who suggests a gloss of “turning to [somebody] for companionship and intimacy. 1924]. 2 vols. that is. stating. Oxford: Oxford University Press. and T. the Septuagint. It is not hard to see why this word is often translated as “desire. and hqw#t 231 lover waits for her beloved. . I address this question briefly elsewhere (Lohr. In that passage. 41:22. See further my “Righteous Abel.Lohr: Sexual Desire? Eve. Genesis 3:16. It uses ἐπιστροφή. a definition that seems more likely influenced by later Hebrew than lexical considerations. Muraoka (A Greek-English Lexicon of the Septuagint: Chiefly of the Pentateuch and the Twelve Prophets [rev.” or “attention. “Righteous Abel. 4). though usually only in later literature.. 2003). the translator(s) took the word to be not hqw#t but rather hbw#t—or perhaps (Die Genesis übersetzt und erklärt [3rd ed. Stuttgart: Deutsche Bibelgesellschaft. 1:76. where the terms ἀποστροφή and ἐπιστροφή are juxtaposed.” given the highly erotic nature of Canticles and the immediate context of the verse.” “turning toward.. 17 For more on ἀποστροφή as “return” and “turning. Wicked Cain. ed. Ezek 16:53. I do not here have the space to engage questions regarding what the Genesis translator was translating. 220.”17 Interestingly. 18:24. 16 The translation is taken from A New English Translation of the Septuagint (ed. When translating Genesis. ed. interpreters regularly raise the plausible explanation of graphic confusion. Sir 16:30. J. 123. Hauspie. the LXX interpreter uses ἀποστροφή in both instances of hqw#t in Genesis (3:16 and 4:7). for example. 2002]. which suggests the gloss “inclination” (in 3:16). Hebrew htpskn Pskn-yk) to go off to your father’s house. Eynikel. one indicating a “turning away” (ἀποστροφή) and the other a “return” (ἐπιστροφή).” and Greek Genesis uses this elsewhere.” “impulse. 15 Again. Wright III. Wicked Cain: Genesis 4:1–16 in the Masoretic Text.” a gloss seemingly derived solely from his reading of LXX Gen 3:16. 27. Greek Genesis might have chosen ὁρµή (“rushing towards..
though he uses ἀποστροφή in 4:7. 126. 23 There are seven main instances of the term (1QS 11:22. Aquila uses συνάφεια (“conjoining.” similar to the translation we observed above in the LXX. though also in the sense of an attack. Whatever the case. and Jubilees Unfortunately. 4Q418 frg. among others. Jubilees.22 Canticles 7:11 is likewise missing (4QCanta becomes fragmented and ends at Cant 7:7). and 4Q495 frg. 24 I here depend on James C. or in union with.19 I will return to this later in the article. “place of refuge” or “place of return. 17:4. 6Q18 frg. “Your place of refuge will be 19 See. a translational practice largely carried forward until the production of the first English Bibles. Leuven: Peeters..g. Theodotion for Gen 3:16 has not survived. “to join to together”). no. Symmachus. 4Q416 2 iv. Eve is told.4 [reconstruction of 1QM]). who states that the word is used here “in sexual connotation.10 [reconstruction of 1QS]. 128. Ronald S. see also n. as we shall see. the LXX is part of a long-standing tradition that understands Eve’s “curse” to involve a “turning” or “return” to her husband. they are missing 3:15–4:1.232 Journal of Biblical Literature 130.20 The other Greek versions vary to a small degree.21 The Dead Sea Scrolls. It is interesting to note that.1. as mentioned. Genesis 4:7. longing. 4Q446 frg. Notes on the Greek Text of Genesis (SBLSCS 35. albeit in fragmented form. The Text of Genesis 1–11: Textual Studies and Critical Edition (New York: Oxford University Press. although the term hqw#t is otherwise rare in extant ancient literature.3 [reconstruction of 1Q26]. Though definitions of ὁρµή may seem close to English ones for hqw#t (e.4) and four reconstructions (4Q256 frg.).” Though it is possible that ὁρµή could be employed in this way. 2 (2011) hbw#t was the reading of the underlying Vorlage.” “union. is found in 4QGenb.” or “close contact. 3:24. on the other hand.23 I will discuss these passages below. usage of this sort would be exceptional. There the text contains [w]tqw#t. 168. 3. Atlanta: Scholars Press.16. 2. however.3. 45. 1QM 13:12. 1Q1 contains 3:11–14. 1. and Roland Bergmeier. yet he will rule over her. desire. 70. the term ὁρµή is never used of a sexual desire but rather signifies a “strong movement toward. The Samaritan Pentateuch is consistent with the MT in its attestation of hqw#t in both Genesis instances. it occurs seven times in the nonbiblical manuscripts from Qumran. Samaritan Pentateuch. 15:10. 20 I discuss this below.” often of the mind. uses ὁρµή.” from συνάπτω. etc. the biblical manuscripts from Qumran do not contain Gen 3:16. in agreement with the MT. uses the term megbā' (ምግባእ). her man. 4Q2 contains 4:2–11. CSCO 510–11. “Zur Septuagintaübersetzung von Gen 3. The Book of Jubilees (2 vols. 1993).1 [reconstruction of 1QS]. 1:19. 21 Pace John William Wevers. and here we get the impression that the pronouncement entails that Eve will be joined to. 1989). VanderKam..” ZAW 79 (1967): 77–79. therefore. Hendel. in my reading of the literature.24 In Jub. 2. For our purposes I refer only to the Ethiopic version. 4Q264 frg. 22 4Q10 contains Gen 3:1–2. as the fragments . 23. 1998).
Unfortunately. and hqw#t 233 with your husband. 10. . 3:24 (the verse related to our study). indicating a type of desire. 29 Definitions are taken from Lewis and Short. G.” OTP 2:60).” Orval S.” or a “grasping at.” Currents in Biblical Research 6 (2008): 405–31. containing introductory material. we might have expected Jerome to employ it in the sexually charged Canticles passage as well.27 The Old Latin (primarily) uses conversio in all three canonical instances of MT hqw#t. Freiburg: Herder. 8.” If appetitus were indeed the closest of the terms to hqw#t. 1879). Oscar Boyd. Genesis (VL 2. “Recent Scholarship on the Book of Jubilees. see VanderKam. Canticum canticorum [VL 10/3.” This then dovetails into his translation of the following line: the man will “have dominion” over the woman (et ipse dominabitur tui).e. In Gen 3:16 he uses phrasing that indicates not “turning” or “desire” but the submission of the woman to the man. The Octateuch in Ethiopic: According to the Text of the Paris Codex. meaning “and under the power of your husband you will be. the Vulgate. 1 of the Canticles critical edition has appeared (Eva SchulzFlügel. For more on the state of the text of Jubilees. this dictionary is preferred here.” a “longing. Of particular interest is Jerome’s decision to render all three biblical instances of hqw#t differently. which he does not. Wintermute translates similarly: “to your husband you will return and he will rule over you” (“Jubilees: A New Translation and Introduction. as P. 2:19. Jubilees. 28 The details may be found in Bonifatius Fischer. where he uses from Qumran and the citations by Greek writers do not include Jub. 1909). Lewis and Charles Short. in that it is believed to be a translation of the Hebrew. 27 In later Latin. Despite its age. however. in Gen 3:16 the matter is further complicated in that Jerome discusses the passage in his later Quaestiones Hebraicae in Genesim. 1951). 26 See J. In his annotations. he will rule over you. Leiden: Brill. It states et sub viri potestate eris. VanderKam notes that “place of refuge” could also be rendered “place of return.Lohr: Sexual Desire? Eve. 2:19. Glare (Oxford Latin Dictionary [Oxford: Oxford University Press. conversio comes to be associated with religious conversion. however. Freiburg: Herder.”29 In Canticles. 25 The translation is from VanderKam. 69–71. 82–83. as well as VanderKam.28 More significant for our purposes is Jerome’s Latin translation. See Charlton T. 1982]) excludes works written later than 200 c. Both Latin terms signify a “turning” or “return” and are therefore good synonyms for the Greek ἀποστροφή. only vol. 464. Jerome translates the term conversio. Whatever the case. A Latin Dictionary: Founded upon Andrews’ Edition of Freund’s Latin Dictionary (Oxford: Clarendon. signifying a “turning” or “return. though it is not in view here. Genesis 3:16. Jubilees. W.26 Latin Versions We turn now to Latin versions.”25 The same term is used in the Ethiopic version of Genesis in both 3:16 and 4:7. In Gen 4:7. The Old Latin tends to use conversio (or occasionally reversio) in its rendering of MT hqw#t. indicating an “attack. 1992]). with Variants of Five Other Manuscripts (Bibliotheca Abessinica 3. Jerome uses the term appetitus.
Jerome’s Attitude to Women.” in The Peshitta as a Translation: Papers Read at the II Peshitta Symposium Held at Leiden 19–21 August 1993 (ed. 1988). “Is the Peshitta a Non-Rabbinic Jewish Translation?” JQR 91 (2001): 411–18. Peshitta scholars agree that there is some evidence of LXX influence on the translation of the Peshitta. Gordon and Maori). “Methodological Criteria for Distinguishing between Variant Vorlage and Exegesis in the Peshitta Pentateuch. 32 This seems to be the consensus in Peshitta studies. Hayward. for instance. is in agreement with the LXX. in this case. In an article that seeks to establish criteria for determining when the Peshitta Vorlage contained a variant or when the translator engaged in translational exegesis. argues that Jerome’s otherwise faithful renderings in the Vulgate appear most slanted and inaccurate in matters pertaining to women. Saint Jerome’s Hebrew Questions on Genesis (Oxford Early Christian Studies. . In Gen 3:16 and the other two instances of MT hqw#t. 1995).30 Coupled with negative comments toward women in Jerome’s other writings. Oxford: Pergamon. 33 Generally. Consult also the review article by Yeshayahu Maori. He argues that there was little—perhaps no—direct LXX influence. diss. See Lund. Hebrew University. Monographs of the Peshitta Institute 8. Dirksen and Arie van der Kooij. see Michael P.34 Maori convincingly argues that differences in the Peshitta and the MT. 1–14. 2 (2011) the term conversio and makes no mention of his translation. Weitzman. For an overview of the issues involved. Leiden: Brill. Jane Barr. Piet B. which challenges Weitzman. “The Vulgate Genesis and St. though never published. 1995). even 30 For more on Jerome’s Quaestiones here. 1982).. 31 Barr. 34 Maori. The Syriac Version of the Old Testament: An Introduction (University of Cambridge Oriental Publications 56. Oxford: Clarendon. though of course detractors certainly exist. the Peshitta translates the term by using the root (“return”). Leiden: Brill. 35.32 The long-standing debates regarding the influence of the LXX on the Peshitta will not here be answered but are certainly relevant. R. 121–28) regarding the essay (between Robert P. 2006). Cambridge: Cambridge University Press. has been instrumental in challenging previous and long-held views. Lund’s study. After Eden: Church Fathers and Rabbis on Genesis 3:16–21 (Jewish and Christian Perspectives Series 10. however.” in Papers Presented to the Eighth International Conference on Patristic Studies Held at Oxford. as also stated in Hanneke Reuling.234 Journal of Biblical Literature 130. 116–17. 38 n. this suggests to some a misogynist tendency in Jerome’s Vulgate (“under the power of your husband you will be”). 1999).31 The Peshitta The manuscripts of the Old Testament Peshitta are also important in that they are generally believed to be a translation of a Hebrew original that was very close (though not necessarily identical) to the MT. 1979 (StPatr 18. Yeshayahu Maori uses Gen 3:16 as an important component in building his case. 103–20.D. The amount of influence. T. 268–73. is under debate. no. see C.33 They are relevant because the Peshitta. Jerome A. and an excellent overview of the relationship between the Vulgate and Quaestiones. “The Influence of the Septuagint on the Peshitta: A Re-Evaluation of Criteria in Light of Comparative Study of the Versions in Genesis and Psalms” (Ph. Consult also the ensuing discussion (pp. 33.
which are clearly referring to turning. I return to this methodological principle in the conclusion below. and Notes [ArBib 6. “Fragments of the Palestinian Targums.”38 35 Here I truncate and simplify a lengthy and nuanced discussion. Song 1:5. 2002). Maori shows that the Peshitta’s use of for MT hqw#t. Collegeville. MN: Liturgical Press. 6:1. A Dictionary of Jewish Babylonian Aramaic of the Talmudic and Geonic Periods (Baltimore: John Hopkins University Press. I here summarize a potentially lengthy discussion. W. Compare Alison Salvesen. 46) and the older translation of J. 3:18–19.” Compare the use in all other occurrences of the term in Onqelos. 5:21. 38 Martin McNamara. Rather. 14:5. A Dictionary of Jewish Palestinian Aramaic of the Byzantine Period (2nd ed. 5:2. Onqelos uses hbwyt.” “repentance.g. He shows that the LXX and Peshitta’s decision to render all three instances of the MT’s term similarly (as “return” or “turning”) likely indicates not variants in all six separate instances but rather a common Jewish exegetical tradition. 32:3. 7:20. 336. Jer 4:1. 61. 1988]. For more on hbwyt. W. 3]). 5:6. Baltimore: John Hopkins University Press. 2:14. “turning. Translated. the Neophyti Targum. Amos 5:12. or repentance: 1 Sam 7:6. 17:11. 33:6. Ezek 7:13. or targumic versions). 42. 1992). inter alia. Longman. 41) translate this as “desire. meaning a “return” or “turning. with Apparatus and Notes (ArBib 1A. 2002). I will return to this idea below. however. even if in direct agreement with the LXX’s ἀποστρφή. 9. 5. 9:5. 1204. Wilmington.”37 It is interesting that Neofiti then includes a marginal note explaining what the “turning” means more specifically: this is “your safety and he will rule over you. as its meaning is not in doubt and all other uses of the term in Onqelos are best translated as “turning” or “repentance. Isa 1:6. see Michael Sokoloff. Bernard Grossfeld and J.” It is not clear why English translations use the term “desire” (e. The Targumim Though perhaps not versions in the true sense. Esth 3:7. Symmachus . Genesis 3:16. (Though the latter might appear to deal only with later literature. 3:40. 4:6. and the Fragmentary Targums” [p. 34:36.35 To be specific for our purposes. and idem. 2:16. with a Critical Introduction. do not necessarily confirm variants in the Vorlage. For reasons of space. 14:7. he argues that we must respect that in many cases translations will reflect a “common Jewish tradition of exegesis” rather than a shared variant. 37 See Sokoloff. the Targums are important for our discussion in that they provide examples—through paraphrase and embellishment—of ancient Jewish interpretation. 12:5. and Roberts. 16:28. In place of hqw#t in Gen 3:16. 31:22. 5.. it covers. vol. Job 21:34. 580. 1.. Eccl 1:15. 1862]. 57:18. Jewish Palestinian Aramaic. Apparatus. Etheridge). DE: Michael Glazier. 36 Both Bernard Grossfeld (The Targum Onqelos to Genesis: Translated.”36 Neofiti is also close to the LXX in its use of btm (from bwt). Lam 1:2. 24:6–7. Genesis and Exodus [London: Longman. 18. and hqw#t 235 when shared with the LXX (or with the Samaritan Pentateuch. 16. Hos 14:5. does not necessarily reflect a variant in the Vorlage. Green. Etheridge (The Targums of Onkelos and Jonathan ben Uzziel on the Pentateuch.Lohr: Sexual Desire? Eve.” or “response. Targum Neofiti 1: Genesis. 19.
and Tg. sich ängstigen. . 1881). accordingly. with Introduction and Notes (ArBib 1B. although Levy’s definitions are similar to Jastrow’s (“Aufregung.” Given the evidence. 2 (2011) Pseudo-Jonathan is more obscure. When one looks up that entry. see Sokoloff. I highlight a few significant examples of interpretation of Gen 3:16 in early Jewish and Christian interpreta- in the Pentateuch (Journal of Semitic Studies Monograph 15.-J. 28. do not contain the term. 41 For more on wt. 118–41. Jastrow. 1991).” a term said to be Late Jewish Literary Aramaic.236 Journal of Biblical Literature 130. it may be that the term is wt (from Babylonian Aramaic wt. His conclusions (pp. Cook’s doctoral dissertation and his own work). MN: Liturgical Press. The Comprehensive Aramaic Lexicon (currently found at.’s Gen 3:16) and in Jacob Levy’s Wörterbuch (which references Gen 3:16. .” Kaufman goes on to describe how “order began to emerge from this chaos” through important studies (e. 40 Levy. . 42 Stephen A. it is difficult to conclude definitively. 1992). Targum Pseudo-Jonathan: Genesis: Translated. Beattie and M. 4:7. 39 See Maher.. (and by implication Late Jewish Literary Aramaic) in this way: “From a linguistic point of view. Jewish Babylonian Aramaic. . McNamara. Wörterbuch. to be a hopeless mess. Sheffield: JSOT Press. Rabbinic.39 It is interesting that. . 124–25.-J. and Jacob Levy. It uses wtm.” or “more”) with a m prefix. 15. Chaldäisches Wörterbuch über die Targumim und einen grossen Theil des rabbinischen Schriftthums (2 vols. meaning “again. . 1994). bwt. erschrecken. esp. Levy suggests that the term is derived from h@wAt. R. D. sich entsetzen. and the challenges involved in the study of Late Jewish Literary Aramaic.edu/) defines wtm as “urge. and some Aramaic dictionaries. 860. hqw#t in Early Jewish. 4:7. Kaufman has rightly characterized Ps. though its meaning is not certain.. Edward M. G. craving.-J.” “leidenschaftliche Aufregung”). the text seems . one is baf@. a word often associated with desire. studies that have increasingly established Late Jewish Literary Aramaic as a distinct. JSOTSup 166.” a definition found in a small entry in Jastrow (which references only Ps. and Song 7:11) and is similar to that found in the Comprehensive Aramaic Lexicon database. bwt in Babylonian Aramaic. “Dating the Language of the Palestinian Targums and Their Use in the Study of the First Century CE Texts. Collegeville. Manchester: Manchester University Press.41 This would be similar to btm in Neofiti (just discussed).huc . no. See Kaufman.g. however. Although it is speculative. fled to find the definitions “erstarren.42 III. 1195–96. authentic Aramaic dialect (albeit a literary one) with its own grammar and lexicon.” in The Aramaic Bible: Targums in their Historical Context (ed. with a meaning of something like “return. 129–30) rightly underline the lexical difficulties involved in the study of Late Jewish Literary Aramaic. 1:80. Michael Maher translates this as “desire.” “heftiges Verlangen. Song 7:11). Gen 3:16. and Christian Interpretation Before we examine the Hebrew term more fully. 2:532. J. Leipzig: Engel.”40 wtm occurs in only three places in Late Jewish Literary Aramaic (Ps.
D. 43 See n. and hqw#t 237 tion. she is plagued by “domestic ills. BJS 232. . Philo addresses Gen 3:16 through a question (QG 1. Hay. David M. by Hanneke Reuling. After Eden. I would suggest that in this case we should resist reading a meaning of “desire” into wtm simply because the term apparently translates hqw#t and we have no other attestations of the Late Jewish Literary Aramaic term.” using the term ἐπιστροφή. 44 Philo. For more on the textual difficulties related to Philo’s QG. Atlanta: Scholars Press.Lohr: Sexual Desire? Eve. for it is a subject of no worth. 31 above.” in Both Literal and Allegorical: Studies in Philo of Alexandria’s Questions and Answers on Genesis and Exodus (ed. 45 According to the note in Marcus. Cambridge. 46 Marcus. (1) The desire of the woman is for none but her husband (Gen 3:16). based on various portions of Scripture.45 The Loeb translation of Ralph Marcus brings this out.49). MA: Hendrickson. but as to a master” (Marcus translation). Our first midrash (Gen. Questions and Answers on Genesis (trans. 47 This is especially apparent when Philo later gives his answer to the question. MA: Harvard University Press. there takes place a turning [ἐπιστροφή/conversio] of sense to the man. Questions and Answers on Genesis (trans. Questions and Answers on Genesis.47 Genesis Rabbah Although a variety of rabbinic sources provide instances of exegetical engagement with Genesis. 223. C. Yonge in this instance rightly translates the same term (ἐπιστροφή/conversio) not as “desire” but as “conversion.7) is interesting in that it takes the opportunity to explain the nature of desire as it relates to four spheres of life. 1991). He speaks not of a curse upon the woman but of the “necessary evils” of life. 1–15.43 Philo In Quaestiones et solutiones in Genesin. Rab. 20. 28. see Earle Hilgert.” 48 Reuling. D. Yonge uses the word “desire. it is interesting to note that Philo speaks not of the “desire” of the woman but of her “turning. Genesis 3:16. “according to the deeper meaning. though the older translation of C. stating. The Latin version uses conversio. Ralph Marcus. LCL 380. it is probably safe to say that “the primary source for rabbinic interpretation of [this book] is Genesis Rabbah. Philo. Questions and Answers on Genesis. Yonge.”44 For our purposes. 800–801.”48 I briefly highlight a few examples of interaction with Gen 3:16 with special reference to hqw#t. I do so briefly and here build on the excellent study After Eden. (2) the desire of the evil inclination is for none except Cain and his assoespecially because our texts are biblical ones.”46 Yonge’s translation seems to be more a reflection of the King James Version of Gen 3:16 than a product of lexical considerations. “The Quaestiones: Texts and Translations. Peabody. 1953). 1993). 28. not as to a helper. The woman experiences pain and toil. 28.
no. It could also be that here we have an ingenious way of explaining what hqw#t is. its meaning being inextricably linked with the idea of returning. It is possible that we are dealing with a sexual desire (i. Immediately following this. . a further midrash is given regarding what the desire might mean in relation to the woman in Gen 3:16. 102. in Didyme l’Aveugle. the term clearly has a wide semantic range here as it has diverse subjects such as rain. blessed be He. Freedman. It is introduced with the common midrashic introduction “Another interpretation is . 165–66.”50 It is interesting that Genesis Rabbah here includes the idea of returning alongside that of desire. as well as the discussion in Reuling. 2 (2011) ciates (Gen 4:7). Midrash Rabbah: Genesis (3rd ed. I briefly provide a sampling of interpretations. 66–67. and God. the midrash makes clear that it we are dealing with something that causes the woman to return to the man.”: When a woman sits on the birthstool..e.238 Journal of Biblical Literature 130. Paris: Cerf. though it could relate simply to a desire for intimacy. After Eden. in his allegorical interpretation of 3:16 (In Genesim 102). says to her: “Thou wilt return [ybw#t] to thy desire [Ktqw#tl]. . thou wilt return [ybw#t] to the desire [tqw#tl] for thy husband [K#y)]. 237.49 Though we could explore each of these ideas separately. 1976). for our purposes I simply note that. (3) the desire of the rain is only for the earth (Ps 65:10). Whatever the case. unless they follow Jerome’s harsher idea of the man’s power and the woman’s submission.” and she has a “turning [τὴν ἀποστροφήν] to her husband”—Christ—who rules over her. Midrash Rabbah. or general desire for the man. London: Soncino. the church experiences “pain that produces repentance [µετάνοιαν] for salvation... Sur la Genèse: ” Texte inédit d’après un papyrus de Toura (SC 233. 50 The translation is from Freedman. understands the church to be the woman. “I will henceforth never fulfill my marital duties. she declares. 1983). . Compare Reuling. hqw#t in the Fathers The fathers use the equivalents of “return” or “turning” (ἀποστροφή and conversio) largely without exception. (4) the desire of the Holy One is for none but Israel (Song 7:11). It is evident that the word by no means implies desire in only strictly sexual terms. trans. After Eden. 165–66. 51 See Pierre Nautin and Louis Doutreleau. IV. the evil inclination. a desire that leads the woman to fulfill her “marital duties”). “In Genesim. although hqw#t seems to be understood as desire.51 Ambrose of Milan is 49 I here loosely quote and paraphrase from H.” whereupon the Holy One. Didymus the Blind and Ambrose of Milan Didymus the Blind.
After Eden. reciprocates by loving his wife (Eph 5:33). Genesis 3:16. 1896). CSEL 32/1. Leipzig: Tempsky. 595. 2. 193. see Gerald Bonner. The husband. Chrysostom Chrysostom uses the Greek term ἀποστροφή in Gen 3:16 to explain the relationship between husbands and wives. 53 See John Chrysostom. . Sermones in Genesim (PG 54:594). Symmachus. for his part.53 The woman will turn to her husband for refuge. however. Evans. As Reuling shows. 15.” in The Cambridge History of the Bible. 429. 1970).72). 541–63. 56 Reuling. [because he] deems it incredible that woman should not have been subject to her husband from the beginning. the extent of his use of the LXX. is a matter of debate. 54 See further Chrysostom. . Peter R. Later. 87–88.” “harbor.” and “protection” (καταφυγή. or least acknowledges. the man will protect her. “Augustine has some difficulty defining [Gen 3:16’s] literal meaning . In his Sermones in Genesim (Sermon 4). After Eden. the decree is a corrective measure to prevent further harm to the human race. vol. Cambridge: Cambridge University Press.”52 Ambrose suggests that the origin of sin lies with the woman. C.55 In his earlier writings.Lohr: Sexual Desire? Eve. see Ambrose of Milan. λιµήν. In doing so. Reluctantly. “Augustine as Biblical Scholar. Compare Salvesen. the original “burden of slavery” implied in Gen 3:16 (“he will rule over you”) is taken away (τὸ φορτικὸν ἀνῄρηται τῆς δουλείας). For a helpful overview. Man. Schenkl. and hqw#t 239 more pointed in his reading of the pronouncement made to the woman. her guilt (“the serpent tricked me”). of course. Ackroyd and C. for definitions. and the discussion in Reuling. thus. 132–34. ἀσφάλεια). see also the discussion in Reuling. refuge from her difficulties. Sermones in Genesim.29). Augustine is reluctant to comment on the “literal meaning” of Gen 3:16 (see Gen. we look at Augustine. Eve’s sentence is made milder because she confesses. After Eden. . as is also. see PGL. therefore. Chrysostom provides three definitions of ἀποστροφή: “place of refuge. she is to “turn [conversa] to her husband and serve him [serviret].54 Augustine Lastly. 55 How much Greek Augustine actually read. 1. F. whose readings are often based either on the Septuagint or an Old Latin translation that uses the term conversio. and rule over her. Chrysostom uses Ephesians 5 to explain things more fully: the woman’s “turning” (or place of refuge) is found in her husband. Augustine decides that Gen 3:16 announces a “changed form of dominance”—the 52 For the text. De Paradiso (ed. In his reading (De paradiso 14. care for her.”56 Following Paul’s understanding in 1 Cor 11:7–9—that only the man was made in God’s image—Augustine argues that the woman’s role has always been subordinate. From the Beginnings to Jerome (ed.
37. and for dust is his longing. a translation of “turning. however. .wtqw#t rp(lw Crwq rmx As what shall one born of woman be considered in your presence? Shaped from dust has he been. within the past six decades (in most cases less). 2 (2011) woman will turn to her husband and he will rule over her. Tigchelaar. interestingly. The Qumran nonbiblical manuscripts.” or “return” is best based on context. Joseph Zycha. 58 Translations are taken from Florentino García Martínez and Eibert J. In other words. no. An interesting test presents itself. how did this ancient community understand and use the term? I will treat the texts in cave order. italics added (here and elsewhere) for emphasis. a new body of ancient literature has become available that is both Jewish and essentially contemporary with our earliest extant translations of the Hebrew Bible. though brief.hkynpl b#{x}y hm h#) dwlyw qwrycm . The Dead Sea Scrolls Study Edition (2 vols. making an important contribution to our discussion. and Reuling.240 Journal of Biblical Literature 130. De Genesi ad litteram (ed. Testing the Interpretive Status Quo through the Dead Sea Scrolls The survey above.57 V. 1894). he is spat saliva. moulded clay. as mentioned. in that. is. from the Rule of the Community. contain seven new instances of the term hqw#t heretofore unknown. 193–95. 371–72. quite straightforward. Prague: Tempsky. The first text. or whether a translation of “turning. CSEL 28/1. After Eden. and it is clear that we cannot base our lexical and interpretive decisions purely on the frequency of a particular translation. What will the clay reply and the one shaped by hand? And what advice will he be able to understand? (1QS 11:21–22)58 57 See Augustine. 11. Service once performed in love now takes on a yoke of slavery. pp. A number of factors make conclusions difficult.wrwdm hmr Mxlw wlbgm rp(m h)whw . here 1:99..Nyby hm tc(lw dy rcwyw rmx by#y hm . The test for our discussion is to see how well a translation as “desire” fits in these instances (thus agreeing with recent translations of the scrolls). the Dead Sea Scrolls. four instances are well preserved. maggots’ food shall be his dwelling. Although three of these occurrences are too fragmentary to be of significance. navigates a large body of literature. 1997). h)whw . Leiden: Brill. C.” or “return” for hqw#t would be virtually definite. If that were the case.
.dxy hmtq[w#t] wyl)w wklhty K#wx yqwxb lbx yk)lm wlrwg dyb hxm#n hktm) .hm+#m K)lm tx#l l(ylb hty#( yxwr lwkw . (1QM 13:11–13)60 Vermes. and Edward M. 88–89. ed. Study Edition. the human is nothing compared to the one who shaped him. in the lot of your truth. rejoice [or ‘let us rejoice’] in your mighty hand. London: Penguin. 1995). 135. C. in view of the history of translation and interpretation sketched above. We. he is spat saliva.. his counsel is to bring about wickedness and guilt. much less) sense contextually. The Dead Sea Scrolls: A New Translation (rev. 59 . . in dark[ness] is his [dom]ain.59 Yet. we exult in your salvation. . What will a heap reply [by#y]. The second text is from the War Scroll: (y#rhl wtc(bw wt[l#mm K]#wxbw .” or “desire” makes little (or minimally.. Abegg. and Wise. The one molded from saliva and clay will return to it. the one born of a woman. All the spirits of his lot are angels of destruction. they walk in the laws of darkness. The Dead Sea Scrolls in English (rev. taken from clay. 1:135. what happens if we translate this with the more frequently used term “turning.hkmwl[#bw hktr]z(b hlygnw hkt(w#yb h#y#nw hktrwbg You made Belial for the pit.” “inclination. Cook (who translate the term as “longing”). Wise. moulded clay. New York: HarperCollins. and hqw#t 241 The above translation of Florentino García Martínez and Eibert J. shall eventually be the food of worms. and extended 4th ed. the one shaped by hand? And what counsel can he understand? The mortal. 60 García Martínez and Tigchelaar. instead.My#)hlw lrwgb wn)w .” or “return”? The results are remarkable in that the passage makes much more sense: As what can he. Dust as the mortal’s “longing. and Cook. Tigchelaar is consistent with that of Geza Vermes (who translates hqw#t as “inclines”) and that of Michael O. the one made of clay is but dust and will return to it. angel of enmity. Genesis 3:16. we revel in [your] aid [and in] your peace.. 2005).Lohr: Sexual Desire? Eve. and his body shall be the food of maggots. In other words. towards it goes their only [de]sire. be considered before you? He has been shaped from dust. Abegg Jr. Martin G. and to dust is his return.
the translation of García Martínez and Tigchelaar. 139. Abegg. 161. may your hearts not weaken]. Abegg. )cmy )wl hmm[# -. New Translation. do not panic. and Wise. Abegg.” while Wise. angels of destruction. no. García Martínez and Tigchelaar. For they are a wicked congregation and all their deeds are in darkness and to it go [their] desires. but I would suggest that a translation of “return” or “turning. and Cook. it is [their] desire. also makes good sense. makes reasonable sense. walk in the statutes of darkness.hm[kbbl Kry l)w wt]xt l)w w)ryt l) Mhy#(m lwk K#wxbw h(#r td( hmh )yk . and Cook. 160. and Cook. and Cook. those in the lot of your truth. 1:137–39.242 Journal of Biblical Literature 130.61 What happens.” given the context. The translation of 13:11–12 could then be rendered something like the following: And all the spirits of his [Belial’s] lot. . Vermes translates the sentence in question as “for they are a congregation of wickedness and all their works are in Darkness. 2 (2011) In this case.rbw( Cwmk ] Mnwm[h] Do not be afraid or [tremble. a reading of “return” also makes sense. See Vermes. their power disappears like smoke. respectively. Study Edition. and Wise. 141.M]tqw#t wyl)w . All the assembly of their [ho]rdes … […] … will not be found. however. do not turn backwards. New Translation. Abegg. and Cook translate it “all their deeds are in darkness. The third text also is from the War Scroll: l)w Mhynpm wcwr(t l)w wzpxt l)w . . to them is their (continual) return. when we put the passage to our test and exchange the above translation of hqw#t with “return”? It is a matter of debate. 63 62 . or [run away from th]em. again in agreement with Vermes and Wise. But let us.”63 In the context of the speaker giving instruction to the faithful not to fear but to stand firm against the army of Belial which will come to nothing. (1QM 15:8–11)62 The translation of García Martínez and Tigchelaar here varies to a small degree from those of Vermes and Wise. they tend towards Darkness. […] their refuge. or be terrified by them.[Mhynpm wswnt] l)w rwx) wbw#t lhq lwkw xlmn N#(k Mtrwbgw Mhysxm[ -. rejoice in your mighty hand and exult in your salvation. Abegg. Scrolls in English. In such 61 Compare Vermes. Scrolls in English.
h(#r tl#mm r# lyp#hlw (ynkhl wd(wm Mwyh And you. and hqw#t 243 a reading the congregation is to stand firm and not be afraid. Today is his appointed time to humiliate and abase the prince of the dominion of evil. do not panic or be alarmed because of them. . the faithful can take courage because the enemy will be powerless and will return to darkness.Lohr: Sexual Desire? Eve. Wise. ] their name shall not be found. though still translating hqw#t as “desire.] in all that will happen eternally. Given the context of the enemy’s eventual ruin. do not turn back.] Mw)ryt l)w wqzxth Mt)w [l)m )yk w(dy])wlw . knowing that the ones whose deeds are in darkness will return to darkness: Do not fear or be discoura[ged. 65 García Martínez and Tigchelaar. a translation of return makes good sense. may y]our [heart not be faint]. Abegg. and Cook. and all their vast assembly [is as chaff which blows away .]w . Study Edition.][ -. [for] their desire goes toward chaos and emptiness. . is remarkably clear in that it alludes to the Hebrew creation story with its use of whbw wht. and their support is without [. New Translation. . (1QM 17:4-6)65 It is unfortunate that the translation of García Martínez and Tigchelaar obscures a clear linkage to creation and the idea that the enemy will.] their strength is as smoke that vanishes. .hyhnw hywh lwk l)r#y . For they are a wicked congregation.64 In other words. Every creature of destruction will quickly wither away . . . The last passage for discussion. [They have established] their refuge [in a lie. be uncreated in the appointed day of judgment.[ly]x )wlb . or [flee from the]m. as for you.Mymlw( yyhn lwkb l[ -. and Cook. A better understanding is achieved in reading hqw#t as “return” rather than “desire”: Mtn(#mw Mtqw#t whblw whtl hmh [)yk -. . . Not [do they know that from the God of] Israel everything is and will be [. in a sense. Genesis 3:16. .]. . take courage and do not fear them [. . not to be a threat again. exert yourselves and do not fear them. . . for] their end is emptiness and their desire is for the 64 I make use here of the reconstructions (and aspects of the translation) of Wise. also from the War Scroll.” make this slightly more transparent: “But. 1:141. . all their deeds are in darkness and to it they will return. 161. Abegg.
67 66 . Despite increased pain in childbearing. understood hqw#t as an action involving the return of the subject or thing. [For] they will return to chaos and emptiness [whblw whtl]. it seems unlikely that the overwhelming number of translational instances of “return” or “turning”—coupled with our findings in the nonbiblical manuscripts of the Dead Sea Scrolls—allow for such a conclusion. and Cook. and Cook. A New (Old?) Translation? Our history of translation and interpretation reveals that ancient Jewish and Christian interpreters regularly. particularly in this instance. The woman who waited for her absent lover in Canticles was certain that her lover would return to her.” signifying that the enemies will return to chaos and emptiness. The remaining instances of hqw#t in the manuscripts at Qumran are either reconstructions of the above or are too fragmentary to be of significance for our purposes. Cain was warned that sin (or perhaps Abel) would return to him. . to indicate a return. if not always. but texts at Qumran seem to use the term quite straightforwardly when a nuanced meaning of “return” is wanted. especially in the light of the history of interpretation presented here.244 Journal of Biblical Literature 130. 2 (2011) void. 163. 68 See n. Abegg. it is altogether plausible. but he could master. Today is his appointed time to subdue and humiliate the prince of the dominion of evil. Based on our examination. return to where they originated: But you. That is. . to suggest that the enemies desire whbw wht. or rule over.” they are basing this on a Vorlage of hbw#t. if not necessary. Their support is without strength and they do not [know that from the God] of Israel is all that is and will be. it. Eve would actively return to the man. New Translation.67 It is less natural. He [. Abegg.] in all that exists for all time. in the above instances where translators use a definition of “turning” or “return. It is more plausible that the Qumran community used hqw#t. often in the context of final destruction or a return to origins. An obvious question comes to mind in that it is plausible that we are dealing not with hqw#t but with hbw#t.”66 In the context of the faithful being encouraged that their enemies will be defeated on the appointed day. 163. I again freely use the reconstructions and translation of Wise. no. Maori’s idea that we are dealing with a “common Jewish traWise. Not only is bw# in some cases used alongside hqw#t. New Translation. 23 above for details.68 V. take courage and do not fear them. however. or they are translating the terms similarly. to read hqw#t as “return.
“drive” (beast). as we have seen. Genesis 3:16. the Bishop’s Bible (1568) (which uses “desire. though perhaps there was a nuance involved whereby with hqw#t there is a strong movement toward.” respectively).71 Our study has demonstrated 69 I have purposely avoided discussions on etymology. Tyndale’s Pentateuch (1530) (which uses “lustes” and “subdued” in the Genesis instances. the Geneva Bible (1587) (which uses “desire” in all three instances). the Miles Coverdale Bible (1535) (which uses “lust. it may simply be that conceptually the term “desire” (in the sense of being naturally driven toward or back to something) was useful in older English but has since become problematic on account of its usage and connotations in a highly sexualized Western society. for ancient interpreters and writers. respectively. yet future work may show that later rabbinic and targumic traditions contributed to modern and recent understandings. or even for destruction or in the sense that the returning is final. equivalent to spalten). and Israel’s God. shank). they seem to fit the literature well. We might conclude that. but it would be difficult to suggest that a confusion of terms was present or that variants of hbw#t existed. The question of where the English translation “desire” (or German “Verlangen”) originates is beyond the scope of this article. it may be helpful to point out that qw# in Hebrew can mean “leg” or “street” (or thoroughfare or market. and the King James Version (1611) (which also uses “desire” in all three instances). equivalent to begehren).” “desire. hqw#t and hbw#t had an overlapping semantic range.” respectively). since the first is related to pregnancy and the second involves two lovers. even in that literature desire in one place will cause the woman to return to her husband.” “desir.” and “turne. It seems more likely that ancients understood hqw#t to be close in meaning to hbw#t. 70 See. though it is not altogether clear why. and in another place desire can have diverse subjects such as rain. 4:7. Luther’s Bibel (1534) uses “vnterworffen” (similar to the Vulgate). and “helt” (from Old German/Sächsische Kanzleisprache. ideas present in some of the earliest—and influential— English Bibles. I think. and some see a connection between qw# and a potential cognate Arabic term also meaning “leg” (esp. Gen 3:16 and Cant 7:10. e. 71 We might also note that the contexts of two of the MT instances. that which a person walks through). Although such ideas are speculative. translated hqw#t as “desire” and have interpreted this to be sexual desire. more often than not. Interestingly. and hqw#t 245 dition of exegesis” is. almost as if part of the genetic makeup of the one (or thing) returning.. the evil inclination.70 Alternatively. altogether plausible. though. returning someone (or thing) to where he or she (or it) belonged. and Cant 7:10 in Wycliffe (1395) (which uses “vndur power.” “subdued.” and “turne. Luther’s 1545 version changes these. and uses “Verlangen” in all three instances.” respectively).g. perhaps of an impelling nature. “las” (from Old German/ Sächsische Kanzleisprache. as I would rather prefer to privilege conclusions drawn from examining the term’s usage than to trace a word’s possible history. perhaps for refuge or to one’s origins.” and “turnyng. However. “impel. .” or “attract” (see entries for qw# in BDB and HALOT). respectively). the translations of Gen 3:16. do not help matters.69 One might suggest that the movement is to an appropriate or natural place.Lohr: Sexual Desire? Eve. interpreters have. Later rabbinic interpretation gives some credence to this definition. In recent translations and interpretation (modern and contemporary).
In view of the discussion above. on how our findings might contribute to an interpretation of that passage. perhaps it is appropriate to comment. through divine pronouncements. and in the light of similar examples in extant ancient literature. in her “curse. 2 (2011) that a definition of “desire” for ancient instances of hqw#t. at least as that term is commonly understood today. The content of these statements is open to question.” said to return (hqw#t. that the man and woman will return to their places of origin. Notes on the Greek Text of Genesis. as a story designed to explain why human existence is what it is. . it would seem that hqw#t (in Gen 3:16) is operating in conjunction with bw#t (in Gen 3:19) to form a type of inclusio. definitions attested earlier. however. VII. the story explains.246 Journal of Biblical Literature 130. 45. in his “curse. no. why life. but the parallelism now apparent should not be overlooked. and daily difficulties are experienced as they are.” “sexual appetite. one that has had—and likely will continue to have—a tremendous influence on religion and society. the situation would likely be quite different. and history of interpretation of the term and has the potential to skew our reading of a foundational text. I think our nuanced understanding of the term has the potential to shed light on how ancient Israel understood the Eden tale to function etiologically—that is.” “unbridled sexual desire. Just as the 'ādām is said. As is commonly noticed. The artistry of the language here is rich and impossible to reduplicate adequately in an English translation. why the daily lives of ancient man and woman are difficult: “by the sweat of your brow you will eat food” and “in pain you will bring forth children. interpreters and lexicons have an obligation to point out ancient perceptions of the term and statements such as Wevers’s that. not only is open to question but cannot be held uncritically any longer. reception. Had our only known instances of hqw#t been Gen 4:7 and the four Dead Sea Scrolls examples examined above.” The text would also like to explain.72 We certainly need to question definitions that relate the term to a “strong libido.” to return (bw#t) to the 'ădāmâ from which he was taken. Conclusion Reading the term hqw#t as sexual desire (or similar) ignores the early usage.” “nymphomania. or be driven to return) to the 'îš from which she was taken. albeit briefly. At a minimum. “[t]he Hebrew word refers to sexual desire” should be qualified or avoided. quite simply. death. so too is the 'iššâ. suffering. 72 Wevers. Because we began our study by looking at interpretations of Gen 3:16.” and so on. | https://fr.scribd.com/document/76055724/130-2 | CC-MAIN-2018-26 | refinedweb | 10,025 | 70.09 |
In this section you will learn how to find the sum of odd number in the series up to the given number in java. The java.io package provide class scanner which read the input from the console. Now here is the simple example which will help you to find the sum of odd number.
import java.util.Scanner; public class Sum { public static void main(String args[]) { System.out.println("Enter the limit number"); Scanner sin; int m,n,sum=0; sin=new Scanner(System.in); n=sin.nextInt(); for(int i=1;i<n;i++) { if(i%2!=0) sum=sum+i; } System.out.println("Sum of odd number = "+sum); } }
In the above program, Creating a class sum and with the help of scanner class getting input from the user, applying a loop which will keep on executing up to the number provided by user. Within the loop checking for odd number in the if statement (i%2!=0), then adding to the sum variable and outside loop sum value will be displayed to the console.
Output : After compiling and executing the above program
If you enjoyed this post then why not add us on Google+? Add us to your Circles
Liked it! Share this Tutorial
Discuss: A program to find the sum of odd number
Post your Comment | http://www.roseindia.net/java/beginners/java-sumof-oddnumber.shtml | CC-MAIN-2015-06 | refinedweb | 221 | 65.01 |
value() Method (xml Data Type)
Performs an XQuery against the XML and returns a value of SQL type. This method returns a scalar value.
You typically use this method to extract a value from an XML instance stored in an xml type column, parameter, or variable. In this way, you can specify SELECT queries that combine or compare XML data with data in non-XML columns.
The value() method uses the Transact-SQL CONVERT operator implicitly and tries to convert the result of the XQuery expression, the serialized string representation, from XSD type to the corresponding SQL type specified by Transact-SQL conversion. For more information about type casting rules for CONVERT, see CAST and CONVERT (Transact-SQL).
A. Using the value() method against an xml type variable
In the following example, an XML instance is stored in a variable of xml type. The value() method retrieves the ProductID attribute value from the XML. The value is then assigned to an int variable.
DECLARE @myDoc xml DECLARE @ProdID int SET @myDoc = '<Root> <ProductDescription ProductID="1" ProductName="Road Bike"> <Features> <Warranty>1 year parts and labor</Warranty> <Maintenance>3 year parts and labor extended maintenance is available</Maintenance> </Features> </ProductDescription> </Root>' SET @ProdID = @myDoc.value('(/Root/ProductDescription/@ProductID)[1]', 'int' ) SELECT @ProdID
Value 1 is returned as a result.
Although there is only one ProductID attribute in the XML instance, the static typing rules require you to explicitly specify that the path expression returns a singleton. Therefore, the additional [1] is specified at the end of the path expression. For more information about static typing, see XQuery and Static Typing.
B. Using the value() method to retrieve a value from an xml type column
The following query is specified against an xml type column (CatalogDescription) in the AdventureWorks database. The query retrieves ProductModelID attribute values from each XML instance stored in the column.
Note the following from the previous query:
The namespace keyword is used to define a namespace prefix.
Per static typing requirements, [1] is added at the end of the path expression in the value() method to explicitly indicate that the path expression returns a singleton.
This is the partial result:
C. Using the value() and exist() methods to retrieve values from an xml type column
The following example shows using both the value() method and the exist() method of the xml data type. The value() method is used to retrieve ProductModelID attribute values from the XML. The exist() method in the WHERE clause is used to filter the rows from the table.
The query retrieves product model IDs from XML instances that include warranty information (the <Warranty> element) as one of the features. The condition in the WHERE clause uses the exist() method to retrieve only the rows satisfying this condition.
SELECT CatalogDescription.value(' declare namespace PD=""; (/PD:ProductDescription/@ProductModelID)[1] ', 'int') as Result FROM Production.ProductModel WHERE CatalogDescription.exist(' declare namespace PD=""; declare namespace wm=""; /PD:ProductDescription/PD:Features/wm:Warranty ') = 1
Note the following from the previous query:
The CatalogDescription column is a typed XML column. This means that it has a schema collection associated with it. In the XQuery Prolog, the namespace declaration is used to define the prefix that is used later in the query body.
If the exist() method returns a 1 (True), it indicates that the XML instance includes the <Warranty> child element as one of the features.
The value() method in the SELECT clause then retrieves the ProductModelID attribute values as integers.
This is the partial result:
D. Using the exist() method instead of the value() method
For performance reasons, instead of using the value() method in a predicate to compare with a relational value, use exist() with sql:column(). For example:
This can be written in the following way: | http://msdn.microsoft.com/en-us/library/ms178030(v=sql.100).aspx | CC-MAIN-2014-42 | refinedweb | 629 | 53.51 |
A view is a callable that receives a request and responds. Django gives an example of several classes you can use like views, so this can be more than just a function. You may arrange your views and reuse code by utilizing inheritance and mixins. There are some generic views for jobs that we’ll go over later, but you may wish to create your reusable view structure that meets your needs. Django provides a set of base view classes you can use in various applications.
Django TemplateView
All views are descended from the View class, which is responsible for attaching the View to URLs, dispatching HTTP methods, and other standard functionality. The TemplateView extends the primary class to render a template and provide an HTTP redirect.
Incorporate it into your URLconf
Creating generic views directly in your URLconf is the most direct approach to use them. You can give a few attributes into the as_view() function call itself if you’re updating a few characteristics on a class-based view:
from django.urls import path from django.views.generic import TemplateView urlpatterns = [ path('about/', TemplateView.as_view(template_name="about.html")), ]
Any arguments supplied to as_view() override any class-level attributes. As a result, we set template_name on the TemplateView in this example. On RedirectView, a similar overriding pattern can be utilized for the URL attribute.
Creating subclasses for generic views
The second, more powerful technique of using generic views is to inherit from an existing view and override attributes like the template_name or methods like get_context_data in your subclass to give additional values or methods.
Take, for example, a view that only shows the about.html template. We can subclass TemplateView and override the template name. Django has a generic view to achieving this – TemplateView – as a result, we can subclass it and override the template name:
# code_app/views.py from django.views.generic import TemplateView class AboutView(TemplateView): template_name = "about.html"
After that, we must include this new View in our URLconf. Because TemplateView is a class rather than a function, we use the as_view() class method to offer a function-like entrance to class-based views:
# urls.py from django.urls import path from some_app.views import AboutView urlpatterns = [ path('about/', AboutView.as_view()), ]
Support for Other HTTP techniques
Assume someone wants to use the views as an API to access our book library through HTTP. Now and then, the API client would connect and get book data for the books published since the previous visit.
However, if no new books have appeared since then, fetching them from the database, rendering a complete response, and sending them to the client is a waste of CPU time and bandwidth. It might be better to inquire about the most recent book’s publication date with the API. In the URLconf, we map the URL to the book list view:
from django.urls import path from books.views import BookListView urlpatterns = [ path('books/', BookListView.as_view()), ]
Below
In the response, an object list is returned using the codemodel_list.html template if the View is requested via a GET request.
On the off chance that the client sends a HEAD request, the response will have no content, and the Last-Modified header will show when the most recent book was released.
It is two-way traffic for the client to download or not to download the entire object list based on this information.
Deep dive into TemplateView
Django Templates are used to build HTML interfaces rendered by Django views. In addition, Django includes many generic views based on classes to help with everyday tasks. TemplateView is the most basic of them all. It renders a given template using the context parameters contained in the URL.
When you wish to present information on an HTML page, you should use TemplateView. On the other hand, if your page has forms and creates or updates items, TemplateView should not be used. FormView, CreateView, or UpdateView are preferable choices in certain situations.
In the following situations, TemplateView is the best choice:
- Showing pages that use GET requests but don’t have any forms. ‘About us’ pages are static and don’t require any context. Context variables are simple to use with TemplateView.
A TemplateView is a class-based view that allows developers to design a view for a particular template without reinventing the wheel. Django provides many generic views, the simplest of which is TemplateView. Subclass TemplateView and provide the template_name via the template name variable to construct a view for an example index.html template.
When you develop views that display static HTML pages without context or forms that reply to GET requests, TemplateView is more convenient. TemplateView is a subclass of the View class that renders a Django template and sends it to the client using some repetitious and boilerplate code.
Example of Django View
Let’s look at making a Django view from scratch before moving on to TemplateView. Let’s suppose we’re making a home view. Below is the needed code you must include in your application’s views.py file.
from django.shortcuts import render from django.views.generic.base import View class Home(View): def get(self, request, *args, **kwargs): return render(request, "index.html")
If our project is called myapp, you must first create a templates/myapp folder within myapp and then add an index.html template. The index.html file is located at myapp/templates/myapp/index.html.
So, how does View help us?
It just exposes the get function, which must contain any code executed when a GET request to the associated URL is made. You don’t need to check for a GET request. Instead, just put your code in the get method. In this example, we utilized extra code to render and return the index.html template using a HttpResponse.
Example of a Django TemplateView
This is where TemplateView comes in. Instead of extending View, override the get method and then use a render function to parse the template and return a HttpResponse object. All you need to do is extend the TemplateView. The preceding example has been changed to use TemplateView:from django.views.generic.base import TemplateView
class Home(TemplateView): template_name = 'index.html'
After that, place your index.html template in the appropriate folder, and you’re ready to go! You don’t have to override the get function, and use renders or another way to implement it. In TemplateView, it’s already done for you.
If you look at the TemplateView implementation, you’ll notice a get implementation that uses the template in the template name variable and renders it. Because this is a typical pattern, it can be easily isolated and defined in its class, which Django developers may reuse without reinventing the wheel.
The definition of context variables and the template name are better separated in TemplateView. In essence, a TemplateView aids you in avoiding boilerplate code such as:
- The need for a GET() implementation
- Creating and returning a HttpResponse() or HttpResponse() subclass object.
The only condition is that you specify in the template is using the template_name variable, as this is the only way for TemplateView to detect the template you wish to render.
Context of a Django Template with a View
Use Template Context if you don’t want your template to be entirely static. Let’s look at how you can use a View class to give your template context. It is the previous example, but this time we’ll pass a primary context object to the template to make it more dynamic.
from django.shortcuts import render from django.views.generic.base import View class Home(View): def get(self, request, *args, **kwargs): context = {'message': 'Hello Django!'} return render(request, "index.html", context=context)
Build a context object, name it whatever you want, and provide the render method as the second parameter.
TemplateView with Django Template Context
Now let’s have a look at the previous example using TemplateView:
from django.views.generic.base import TemplateView class Home(TemplateView): template_name = 'index.html' def get_context_data(self, *args, **kwargs): context = super(Home. self).get_context_data(*args, **kwargs) context['message'] = 'Hello World!' return context
If you’re using TemplateView, you’ll need to utilize the get_context_data method to give your template any context data variables. You rename the get_context_data function and provide an implementation that receives a context dict object from the parent class (in this case, TemplateView) and adds the message data.
Then, in your index.html template, you may utilize interpolation curly brackets to display your context variable.
<p>{{message}}</p>
Using as_view with TemplateView and URLs
After you’ve defined the sub-class of TemplateView, you’ll need to map it to a URL in your project’s urls.py file. To do so, use TemplateView as a view method, which provides a callable object. The latter is provided as the second parameter to the route method, which correlates URLs with views.
Consider the following scenario:
from django.urls import path from myapp import views urlpatterns = [ # [...] path('', views.Home.as_view()) ]
Using TemplateView in urls.py
You can use TemplateView directly in your URL for even simpler scenarios. This allows you to render a template more quickly:
from django.views.generic.base import TemplateView from django.urls import path urlpatterns = [ # [...] path('', TemplateView.as_view(template_name='index.html')) ]
You can supply the template name as a keyword argument to TemplateView’s view method.
Conclusion
Django includes several generic views based on classes to help with everyday tasks. TemplateView is the most basic of them all. As a result, when presenting information on an HTML page, TemplateView should be utilized. On the contrary, if your page has forms and creates or updates items, TemplateView should not be used.
In some instances, FormView, CreateView, or UpdateView are preferable. However, in the following situations, TemplateView is the best choice:
- Showing ‘about us’ pages that are static and don’t require many contexts.
- Context variables are simple to use with TemplateView.
- Showing pages that use GET requests and don’t contain any forms.
Django’s generic TemplateView view class allows developers to easily create views that display simple templates without reinventing the wheel. Subclass TemplateView and set the template name variable to the name of the template you want to use. You should have this template in your templates folder. | https://www.codeunderscored.com/templateview-in-django/ | CC-MAIN-2022-21 | refinedweb | 1,725 | 57.27 |
Coming in Zeebe 0.22: Awaitable workflow outcomes
The upcoming 0.22 release of Zeebe includes a feature many users have been asking for: the ability to start a workflow and retrieve its outcome with a single command.
The new gRPC command
CreateWorkflowInstanceWithResult is available for testing in the current SNAPSHOT Docker image of Zeebe and the
zeebe-node-next version of the Node.js client.
This command starts a workflow instance and returns the outcome when the workflow completes.
Use-cases
A common scenario is to start a workflow in response to a REST request, and send back the outcome from the workflow in the REST response. Previous implementations of this relied on a polling worker to retrieve the outcome, and the use of subscriptions to correlate it with the REST request context (See the “Zeebe Workflows Inside a REST Request/Response” blog post and the zeebe-node-affinity package). This scenario makes sense when the workflow is short-running.
A Tour of Related Issues and PRs
The initial feature request for awaitable workflow outcomes - #2896 - got a lot of traction and input from the community. This is the best way to get something implemented in Zeebe: open a feature request, make a compelling use-case with a good description, and get wider community support for it.
The work to implement the functionality in the broker has been done by Deepthi Akkoorath, and is in this pull request. If you work with Zeebe and are interested in this feature, I recommend you read through the changes. I can’t overstate the value of reading the source code to build up your understanding of using Zeebe. All the answers are in there. You may not understand everything, but you never will if you don’t start somewhere, so dive in!
Awaiting workflow instance results is implemented in an upcoming release of the Java and Go client (#3286), and in the testing version of the Node.js client,
zeebe-node-next (example).
The work to support it in
zbctl is still to be done, and is being tracked here.
An example using Node.js
Here is how you use the feature with the current SNAPSHOT Zeebe server and
zeebe-node-next:
import {} from 'zeebe-node-next' async function main() { const zbc = new ZBClient() await zbc.deployWorkflow('./test.bpmn) const initialVariables = { clientId: 1 } const outcome = await zbc.CreateWorkflowInstanceWithResult( 'test-process-id', initialVariables, ) console.log(outcome.variables) } main()
Dealing with gRPC request timeout
An important consideration here is the gRPC request timeout. By default, this is the request timeout configured on the Zeebe gateway (15 seconds, out of the box). If your gRPC request times out before the workflow completes, the client will receive a request timeout error back from the gateway. If this happens, you will not have a workflow instance Id for the workflow that you just created.
You can retry the request - note that each retry creates a new workflow instance, so you should ensure that any side-effects in the workflow are idempotent. If the broker timeout is due to load, it may succeed on a subsequent execution. But if the workflow takes intrinsically longer than the timeout, you will never get a result back. So you need to configure the request timeout to be of sufficient length.
You can override the gateway request timeout by using a different signature for the
createWorkflowInstanceWithResult call in the Node client (the C#, Go, and Java clients use a builder pattern, so constructing the command differs in those clients):
async function main() { const result = await zbc.createWorkflowInstanceWithResult({ bpmnProcessId: processId, variables: { sourceValue: 5, otherValue: 'rome', }, requestTimeout: 25000, }) return result } main()
Also to note: since no workflow id is returned until the workflow completes, if your system experiences a failure while the request is pending (either client-side or on the broker), you will have no way to correlate the request.
Constraining the returned variables
A further feature (#3253), that hasn’t been merged at the time I wrote this blog post, is the ability to constrain the variables returned by the call.
When this lands, you’ll be able to do this:
async function main() { const result = await zbc.createWorkflowInstanceWithResult({ bpmnProcessId: processId, variables: { sourceValue: 5, otherValue: 'rome', }, fetchVariables: ['finalBalance'] requestTimeout: 25000, }) return result.variables.finalBalance } main().then(console.log)
Summary
The new CreateWorkflowInstanceWithResult command allows you to “synchronously” execute workflows and receive the outcome. It’s a popular feature request in the community and will reduce the complexity of Zeebe systems in production that have been using complex patterns to achieve this functionality.
The feature is ideally suited to workflows that retrieve information in response to a request, and return it in the response. If your workflow mutates system state, or further operations rely on the workflow outcome response to the client, take care to consider and design your system for failure states and retries.
Bonus
I live stream coding with Zeebe and Node.js, weekly on Twitch.
Here are a couple of videos from this week’s stream, implementing support for this feature in the Node client. | https://zeebe.io/blog/2019/10/0.22-awaitable-outcomes/ | CC-MAIN-2020-16 | refinedweb | 845 | 52.09 |
MvPts-macro
Opens the Data Reader tool and places it in the active graph window. Writes usage information on the status bar. If the dataset dataset has moveable points, it will allow you to move its data points by clicking and dragging them with the Data Reader tool.
Def MvPts {
def PointProc {{EndToolbox};doTool 0};
doTool -cntrl 3 ($Exemessage.MovePts);
doToolbox -r %1;doToolbox -key;
};
The following script sets the data points of the dataset MyData1 as moveable and then executes the MvPts macro allowing its data points to be moved with the Data Reader tool.
Set MyData1 -m 1;
MvPts MyData1; | http://cloud.originlab.com/doc/LabTalk/ref/MvPts-macro | CC-MAIN-2021-10 | refinedweb | 102 | 71.85 |
Difference between revisions of "Physics:2D Physics Engine:Intersection Detection"
Latest revision as of 19:20, 3 July 2014
The following article is part of a series:
- Introduction
- Collision Detection
- Intersection Detection
- Collision Detection
- Resolving the Collision
- Rigid Bodies
- Extra 'stuff'
- Conclusion
Contents
Intersection Detection versus Collision Detection
Before progressing any further I'd like to share the difference between intersection detection and collision detection. An intersection test will tell you if two shapes or objects are interpenetrating at a given time. On the other hand a collision test will tell you if two objects will collide over a period of time.
A common example of a wrongly-named collision detection algorithm is the case of two intersecting circles. The test is commonly described:
- "Given two circles with a center at point P, with radius R, the circles are colliding if the sum of the radii are greater than the distance between the two circles."
This is actually an intersection test, because it tests if the two circles are intersecting at their given positions. If the circles were not intersecting, but were moving towards each other very quickly, then they would be colliding. However, this test will not tell us that.
Why is this important? It isn't, really. However, it is information that will keep you from wondering why someone's 'collision test' doesn't work at high speeds.
Circle Intersection
Firstly, the most simple shape to detect intersections between is the circle. You can think of a circle as a point and a radius. All you have to do to check whether two circles are intersecting, is to check whether the distance between the centers is greater than the radius. If it is, the two circles aren't touching.
Here is a simple implementation written in Python
import math class Circle: def __init__(self, radius=1, x=0, y=0): self.radius = radius self.x = x self.y = y def circle_intersect(circleA, circleB): # returns true if circles are overlapping dx = circleB.x - circleA.x # get change in x dy = circleB.y - circleA.y # get change in y dist = math.sqrt(dx * dx + dy * dy) # find distance between centers of circles # if the distance between the centers of the circles is less than the combined # radii, then the circles must be overlapping return circleA.radius + circleB.radius > dist
Separating Axis Theorem for Axis Aligned Rectangles
A lot of games don't need complicated collision systems to find out whether two rectangles are intersecting. The code to find this is quite simple
class Vect: def __init__(self, x=0, y=0): self.x = x self.y = y class Rect(Vect): def __init__(self, w=0, h=0, x=0, y=0): self.x = x self.y = y self.w = w self.h = h def rectangle_ovlbool(a, b): c1 = (a.x - a.w) < (b.x + b.w) c2 = (a.x + a.w) > (b.x - b.w) c3 = (a.y - a.h) < (b.y + b.h) c4 = (a.y + a.h) > (b.y - b.h) return c1 and c2 and c3 and c4
A good explanation of how this works can be found here and a visual representation here.
The Separating Axis Theorem
The Separating Axis Theorem (referred to as SAT from now on) is a method to quickly and efficiently decide whether or not two convex polygons intersect.
The SAT involves projecting the two polygons onto every axis of both polygons. If these projections intersect on all axes, then the polygons are intersecting. However, if any of the projections are not intersecting, the polygons are not intersecting.
Procedure
- Look at the pictures. They are much easier to understand.
- For each edge vector of both polygons:
- Determine the separating axis. To compute the separating axis:
- Find the unit vector of the edge (vector of magnitude 1)
- Find the normal (perpendicular) of that unit vector
- For each polygon:
- Find the dot product between each point in that polygon and the separating axis
- The projection of that polygon onto the separating axis spans between the smallest of those projected points and the largest of them
- If the projections do not intersect, stop. That means the polygons are not intersecting.
- If step 2 was completed, the polygons must be intersecting.
Implementation
The following code is written in Python, but should be readable for users of other languages as well. It may look daunting, but just take it step by step. You can probably skip over the Vector class (it's fairly standard), but it is included for completeness.
import math class Vector: """Basic vector implementation""" def __init__(self, x, y): self.x, self.y = x, y def dot(self, other): """Returns the dot product of self and other (Vector)""" return self.x*other.x + self.y*other.y def __add__(self, other): # overloads vec1+vec2 return Vector(self.x+other.x, self.y+other.y) def __neg__(self): # overloads -vec return Vector(-self.x, -self.y) def __sub__(self, other): # overloads vec1-vec2 return -other + self def __mul__(self, scalar): # overloads vec*scalar return Vector(self.x*scalar, self.y*scalar) __rmul__ = __mul__ # overloads scalar*vec def __div__(self, scalar): # overloads vec/scalar return 1.0/scalar * self def magnitude(self): return math.sqrt(self.x*self.x + self.y*self.y) def normalize(self): """Returns this vector's unit vector (vector of magnitude 1 in the same direction)""" inverse_magnitude = 1.0/self.magnitude() return Vector(self.x*inverse_magnitude, self.y*inverse_magnitude) def perpendicular(self): """Returns a vector perpendicular to self""" return Vector(-self.y, self.x) class Projection: """A projection (1d line segment)""" def __init__(self, min, max): self.min, self.max = min, max def intersects(self, other): """returns whether or not self and other intersect""" return self.max > other.min and other.max > self.min class Polygon: def __init__(self, points): """points is a list of Vectors""" self.points = points # Build a list of the edge vectors self.edges = [] for i in range(len(points)): # equal to Java's for(int i=0; i<points.length; i++) point = points[i] next_point = points[(i+1)%len(points)] self.edges.append(next_point - point) def project_to_axis(self, axis): """axis is the unit vector (vector of magnitude 1) to project the polygon onto""" projected_points = [] for point in self.points: # Project point onto axis using the dot operator projected_points.append(point.dot(axis)) return Projection(min(projected_points), max(projected_points)) def intersects(self, other): """returns whether or not two polygons intersect""" # Create a list of both polygons' edges edges = [] edges.extend(self.edges) edges.extend(other.edges) for edge in edges: axis = edge.normalize().perpendicular() # Create the separating axis (see diagrams) # Project each to the axis self_projection = self.project_to_axis(axis) other_projection = other.project_to_axis(axis) # If the projections don't intersect, the polygons don't intersect if not self_projection.intersects(other_projection): return False # The projections intersect on all axes, so the polygons are intersecting return True
[a note from thebluedragont] If you want to move out of intersection straight away, add to your position the inverse of one of the intersection axes multiplied by one of the overlaps: -axis * overlap.
If you want to move in a logical way (if you hit a wall you don't suddenly want to go upwards, do you?), add only the smallest overlap you got with the inverse of its axis.
For example, if you do a check against two AABBs and you get that they are intersecting, see what the overlaps are (I do it by regarding each Projection struct as a circle and do a simple circle-circle overlap test). Say you got that the overlap on the X axis is 10 and the overlap on the Y axis is 13 - you need to move your object -10 units on the X axis.
I also suggest reading this article . It explains in great detail about SAT and some common shapes, but doesn't really talk much about HOW to actually do everything. Thereof, it wouldn't be complete without this page, and Gman's other page (which I honestly think is better then this one) which explains more about the "HOW to do it". | http://content.gpwiki.org/index.php?title=Physics:2D_Physics_Engine:Intersection_Detection&curid=4392&diff=32397&oldid=26134 | CC-MAIN-2015-32 | refinedweb | 1,352 | 56.35 |
Introduction to Switch Statement in C
Before we learn what is Switch statement in C, let us first understand what is C.
C is a procedure-oriented programming language developed by Dennis Ritchie. The basic purpose behind developing the C language was to use it as a programming language of the system i.e to program an operating system. Many languages borrow their syntax from this C language. C++, for instance, is an extension or can be considered as an upgraded version of C programming language.
What.
4.6 (3,144 ratings)
View Course
The syntax for switch statement in C programming language is given below-
syntax :
switch( expression )
{
case value1:
//Block of code;
break;
case value2:
//Block of code;
break;
case valueN:
//Block of code
break;
default:
//Block of code
break;
Example:
This example will give more clarity about the use of switch statement
#include <stdio.h>
int main () {
char grade_report = 'D';
printf("Your performance is : ");
switch(grade_report) {
case 'A' :
printf("Outstanding Result!\n" );
break;
case 'B' :
printf("Excellent Result!\n" );
break;
case 'C' :
printf("Good Result\n" );
break;
case 'D' :
printf("Satisfying Result\n" );
break;
case 'F' :
printf("Poor Result\n" );
break;
default :
printf("You did not appear for exam\n" );
}
return 0;
}
Output:
Your performance is: Satisfying Result
Flowchart of Switch Statement
How Switch Statement Works.
Let us have a look at few more examples –
Example:
This example depicts the use of break statement in switch. If the break statement is not specified after the case, the execution flow will continue until it encounters the break statement.
#include <stdio.h>
int main() {
int range_of_number=50;
switch (range_of_number) {
case 10:
case 20:
case 30:
printf("The number is 10 or 20 or 30 ");
break;
case 50:
case 55:printf("This case also executes because there is no break ");
printf("\n");
case 60:
printf("The number is either 40 or 50 or 60");
break;
default:
printf("The number is greater than 60");}}
Output:
This case also executes because there is no break
The number is either 40 or 50 or 60
Example:
#include <stdio.h>
int main()
{
int x = 10, y = 5;
switch(x==y && x+y<10)
{
case 1:
printf("hi");
break;
case 0:
printf("bye");
break;
default:
printf(" Hello bye ");
} }
Output :
bye
Example:
Nested Switch Statement.
#include <stdio.h>
int main() {
int ID = 300;
int password = 1000;
printf("Enter Your ID:\n ");
scanf("%d", & ID);
switch (ID) {
case 300:
printf("Enter your password:\n ");
scanf("%d", & password);
switch (password) {
case 1000:
printf("Welcome to the portal\n");
break;
default:
printf("Enter correct password");
break;
}
break;
default:
printf("Enter correct ID");
break;
}
}
Output :
This will depend upon the values entered by the user.
Output 1 :
Enter Your ID: 300
Enter your password: 1000
Welcome to the Portal
Output 2:
Enter Your ID: 100
Enter correct ID
Output 3:
Enter Your ID: 300
Enter your password: 000
Enter correct password
Conclusion
Switch case statements are a controlled also discuss the Introduction and How Switch Statement Works in C. You may also have a look at the following articles to learn more – | https://www.educba.com/switch-statement-in-c/ | CC-MAIN-2019-47 | refinedweb | 512 | 52.02 |
The Hundred-Year Language 730
dtolton writes "Paul Graham has a new article called "The Hundred-Year Language" posted. The article is about the programming languages of the future and what form they may take. He makes some interesting predictions about the rate of change we might expect in programming languages over the next 100 years. He also makes some persuasive points about the possible design and construction of those languages. The article is definitely worth a read for those interested in programming languages."
Seymour Cray said it best (Score:5, Funny)
I do not know what the language of the year 2000 will look like, but it will be called FORTRAN. [cmbi.kun.nl] -Attributed to many people including Seymour Cray, John Backus
Re:Seymour Cray said it best (Score:4, Funny)
Re:Seymour Cray said it best (Score:3, Funny)
2100: No computer Languages. (Score:4, Insightful)
Planet P Blog [planetp.cc]
I predict... (Score:5, Funny)
And I will still be refusing to maintain them. Six years in the COBOL mines was six years too long...
Re:I predict... (Score:5, Funny)
I predict that in 100 years someone, somewhere, will still be running COBOL applications.
And I will still be refusing to maintain them.
Surely that depends on whether you're damned or not. I imagine there's a whole circle of hell devoted to maintaining COBOL apps.
Cobol is back. (Score:4, Funny)
how long (Score:3, Insightful)
xao
Re:how long (Score:5, Interesting)
\ Word definitions : convicted-of 0 ; \ To convict someone : murder 25 + ; : arson 10 + ; : robbery 2 + ; : music-copying 40 + ; : sentenced-to .
." years of prison" ;
And to use it:
convicted-of music-copying robbery sentenced-to
Output: 42 years of prison This looks quite like english. Of course, you can do that in many languages, but it feels more natural in Forth I think.
Re:how long (Score:5, Funny)
Re:how long (Score:2)
Not long... (Score:4, Informative)
In fact never. Because while its okay human languages have a few problems
1) Redundancy, far to many ways to say or do one thing
2) Ambiguity, "1 may be equal to x" "Sometimes allow the user to do this if they aren't doing something else that might conflict"
So what you might get is a restricted language with restricted terms that could help. But even these tend to fall down, the first UML spec was written using such a language but this was abandoned for the more formal UML language as the inherent ambiguities of languages couldn't be overcome.
So basically you might have some mechanism of translating from formal into informal but the real work will be done in a formal manner, as now, as ever because at the end of the day....
Who wants to rely on a system that implements "sometimes" ?
Re:Not long... (Score:4, Insightful)
In fact never. Because while its okay human languages have a few problems
Well, yeah, but doesn't a computer language suffer from the same pitfalls? If that isn't the case, why do languages tend to "evolve" over time? Why are new languages that borrow elements from other languages so prevelant?
1) Redundancy, far to many ways to say or do one thing
Isn't one of the driving principles of Perl "There's more than one way to do it"? Some say this is one of Perl's best feature, other's say it sucks.
I won't argue with the point of ambiguity. You can remove ambiguity from a "spoken" language by applying rules to it. I do think we're quite far away from being to "speak" a program, but that's because we as a culture have moved away from a _grammar_ of English. Check the courses in a university and see what first year English and Linguistic students are taking. It's not Grammar, it's Grammars. Standard written English is a thing of the past. So we won't base a language on how we actually use our language, but we could base a language on certain grammars of the language. And, isn't that something else that languages like Perl and Python try to do? They try to create more "readable" programs?
English and Grammar... (Score:4, Informative)
English actually doesn't really have a written Grammar BTW, English was the language of the poor people not of the gentry therefore it evolved as a loosely ruled language rather than as a language with definate constructs like proscribed Latin or modern German.
Basically English is the language of plebs, the rich and diplomats spoke French. The idea of a grammar was retro-fitted by the Victorians who applied Latin rules to English which just don't fit.
Lets put it this way, in English you can screw with the language as much as you want and it continues to change every year. This is fine as it makes it a rich communication tool.
What other languages can use one word to make an entire sentence ?
F*ck's F*ckers F*cking F*cked
Re:English and Grammar... (Score:3, Interesting)
Latin:
The colloquial translation:
And, although Latin is inflected but English is only partially inflected, all of the words are identical!
;-)
So HAH.
This sort of poetry is common in obfuscated C contests, although the visual lack of distinction between 0 and O and I and 1 is also commonly needed.
-Billy
Re:how long (Score:4, Interesting)
For unsupervised commands humans tend to create something not all that different from code. A fixed set of grammar and vocabulary come into play (i.e. little slang, and very normalized style). For example:
Employees will update thier status on the In/Out board in the lobby when they will be gone for more then 15 minutes.
which is roughly:
(if (> (expected-completiontime task) 15)
(update-status out))
So the need and utility isn't there.
Re:how long (Score:3, Interesting)
Structurally, spoken languages and computer languages are very similar:
Phonetics: sounds
Phonology: sounds in relation to one another
Morphology: words
Syntax: structure (words in relation to one another)
Semantics: meaning
Pragmatics: meaning in context.
Morphology, Syntax and Semantics are shared by human and computer languages. Arguments could be made about phonology, too, but not by me. Some computer langauges might even have pragmatics. (Example of pragmati
Re:how long (Score:5, Insightful)
This is a false and limited conception of the original poster's intent. Imagine having an A.I. on a PDA-type device that you carry with you from the age of 4. The PDA has a 100Terabye HD, and records/monitors your spoken words, actions, etc. After 20 or 30 years of this, your PDA probably knows you better than anyone. So if you tell your PDA "make a cool program that looks like this, and does this" there's a very good chance it understands what you mean.
Think about police sketch artists. They take vague, half remembered information...and turn it into a very accurate rendering of the original image. You have a vague idea in your mind of what you are describing, and you can't see what he/she is drawing. So you describe the person...and 5 minutes later the artist shows you a rather remarkable portrait of what you described. Which in many cases later turns out to very closely resemble the suspect. The missing link here is context. The context of shared culture and language.
If you can sit at a table and describe the basic functionality of a program, and describe its interface using words. Then your magic PDA will do the rest. It will even give you demos and visual feedback on the fly as you describe the program. It would serve as a layer between the absolutely massive context of your personal history, and the "structured" programming language required to build said program.
Please don't limit the future, it's bigger than you are.
Re:Interactivity (Score:3, Informative)
Also, think about languages like Ruby or Lisp where the interpreter can alter a program while it's running. As an example I wrote a small text editor in Ruby/Tk in which you could modify the source code to the editor in a buffer, then choose "eval buffer in application", and that code would run in
Re:how long (Score:4, Insightful)
The actual source code (i.e. the instructions to the processor) should be surrounded by quote marks or other delimiters, and the comments (i.e. the extended code description and documention) should be the part of the source surrounded by white space characters (space, tab, cr/lf).
I never cease to be amazed at how little programming has changed since the 1960's. It really seems that the only innovation in compilier user-interface design has been that (some) compiliers will actually allow you to put your keywords and comments in color! (duh!)
If we are ever going to increase the productivity of programmers to even remotely match the vast increases in price/performance of the the hardware then we must be willing to spend large amounts of time energy and money to develop new and better approaches to writing software code.
We must abandon our kilobyte mentality to gigabyte technology!
As an example of a different approach, has anyone considered using Chinese characters arranged in a three-dimensional grid as a method of doing syncronous parallel programming? Have each character represent a complete function and have their placement in the 3-D grid space represent the point in the algorymthic process that the function should be complete. The compilier would either create the machine language or suggest other arrangements of the parallel process by rearranging the Chinese characters in the 3-D user interface.
(The fact that it sounds weird is not important. What is important is that any new idea that can help improve the productivity of programmers should be considered, regardless of how strange it may sound at the present time)
Thank you,
Aliens (Score:3, Funny)
Presumably many libraries will be for domains that don't even exist yet. If SETI@home works, for example, we'll need libraries for communicating with aliens. Unless of course they are sufficiently advanced that they already communicate in XML.
Let's hope it's not Microsoft's XML, because that could cause a problem with communication:they might say "We come in peace" and start shooting at us with lasers and everything!
No current languages will exist.. (Score:5, Funny)
Convergence (Score:2, Insightful)
For species branches can converge too - it's just kind of weird...
Re:Convergence (Score:3, Funny)
So you've been getting that xxx farm girl spam too...
dead-end? (Score:2, Insightful)
dead-end? Java has already spawned javascript and C#.
Re:dead-end? (Score:2)
Re:dead-end? (Score:5, Informative)
Re:dead-end? (Score:5, Insightful)
Comparing JavaScript and Java is like comparing a Shark to a Dolphin, quite different actually even though both animals live in the sea, and both languages use the letters J A and V. Both have cariovascular systems and both use variables and control structures. But that is basically where the similarities end.
JavaScript actually started life inside of Netscape as LiveScript, and durring the Netscape 2.0 time frame was re-named to JavaScript to ride the Java bandwagon, but thre is no realtionship at all beyond that. Compile-time type saftey? Java yes JavaScript no. Prototypes? JavaScript yes Java no. eval() of new programming code? One but not the other. Interface inheritance? Again. First Class Methods? yep, not both. Bones? Sharks no Dolphins yes (teeth don't count).
Now C# and Java, they are at best siblings but java did not beget C#. The namespace structure is straight from Ansi C++, and the primative types include Cisims like signed and unsigned varieties. You don't shed a tail and then grow it back further down the trail. The comparison here is alligators and crocidiles. Very similar but one did not beget the other, it was a closer common parent than the sharks and dolphins.
Yep, dead end (Score:4, Informative)
...Neither of which has done anything to advance the state of the art in programming languages, even if your claim were true.
The one thing I have confidence in about programming in the future is that sooner or later, the tools and techniques with genuine advantages will beat the "useful hacks". Java, C++, VB and their ilk are widely used today because they can get a job done, and there's not much better around that gets the same job done as easily.
Sure, there are languages that are technically superior, but they're so cumbersome to use that no-one really notices them, and when they do, you don't have the powerful development tools, the established code base of useful libraries, the established user base of developers to hire, etc. When we get to the point that languages with more solid underlying models catch up on ease of use, then we'll relegate the useful hacks to their place in history as just that. Until then, we'll keep using the useful hacks because we have jobs to do, but don't expect the tools of the future to be built on them.
moores law (Score:2)
AI (Score:2, Interesting)
Best quote from the article (Score:5, Insightful)
Re:Best quote from the article (Score:5, Funny)
Re:Best quote from the article (Score:4, Informative)
Ha. I always thought it would look more like:
Why Change? (Score:3, Insightful)
Re:Why Change? (Score:3, Insightful)
Safer languages. Forget typesafe languages, we'll have typeless languages. And then the algorithms will be intensely abstracted as well. We'll have functional composition with a usable syntax. We'll create GUIs by overloading the + operator to handle components. And of course, automatic runtime code reuse will be an assumed feature of the language.
And of course, the past fifty years teaches us that it
Re:Why Change? (Score:3, Insightful)
The horror (Score:4, Funny)
VIOD THING (OMFG!!!1 LOLOLOLOOL!!!)
INIT HAX0R N00B!!!
WHIEL STFU DO
GOTO 10
DOEN
Awareness... (Score:5, Insightful)
Imagine cars that, before changing lanes, signal to the surrounding cars' navigation systems and they work out for themselves how to let the car into the lane. A computer can be told to slow down, rather than speed up, when someone wants to change lanes. Or detectors in the dotted yellow lines that sense when you changed lanes without signalling, and alert the traffic authority to bump your points (ala Fifth Element).
I always liked the idea of my PDA phonebook being more of a recently-used cache of numbers instead of a local store. I just punch up a number. If it's one of my commonly used ones, it comes right up (and dials, of course). But if it's not, then my PDA connects to the phone company, gets the information (and probably pays the phone company a micropayment for the service) and now I have that number locally on my PDA until it gets scrolled off if it's not used much.
Also I expect lots of pseudo-intelligent content filtering software. You'll get 1000 emails a day and your spam filter will not only remove 99% of them, but it will also identify and prioritize the remaining ones. In order for this to be useful there needs to be languages that deal with expression of rules and logic in a meaningful way (far more than just and or not). No one 100 years from now will say "if subject ~=
/*mom*/" (or however the hell you say it), they will expect to say "Give email from mom a higher priority", or sometihng very close.
Re:Awareness... (Score:5, Interesting)
Travis
Evolutionary dead-end? (Score:3, Interesting)
Er... I don't think that Cobol is an evolutionary dead-end; in the best world, it would be extinct, but it isn't. What makes a language widely used is something that we can't predict right now - we have to watch it evolve over time, and as it grows and matures look at different aspects.
Take architecture for example - new buildings are loved the first five years because of their freshly introduced ideas. After that, all the problems start to appear - mildew problems, asbestos in the walls, and so on. During the next ten years, the child diseases are fixed. It is only a HUNDRED YEARS after the new building (or in our case, the new programming language) can be properly evaluated. The language/building then has either been replaced, or it has survived.
So - the only proper way to measure the successfulness of a programming language is to measure its survivability. Sure, we can do guesstimates along the way:
During introduction: Does the language have a good development environment? Is the language backed/introduced by a market leader?
Somewhere during the "middle years" (after about ten years): Does the language have a large user base? Does the language have a large code base?
After twenty/thirty years: ask the programmers if it really is maintainable...
Well - you get the picture! Predicting the survability of something more than five years into the future is impossible, I'd say.
Waste of Time (Score:3, Insightful)
huh!?!?
This is the kind of mental constipation that is better left for blog sites.
Somewhere there is parallel between the logic in this article and the dot.bomb busniess model.
I know the name of the language. (Score:2)
-russ
History and Future (Score:5, Interesting)
Re:History and Future (Score:4, Informative)
I wouldn't read too far into this article... (Score:4, Insightful)
It may seem presumptuous to think anyone can predict what any technology will look like in a hundred years...Looking forward a hundred years is a graspable idea when we consider how slowly languages have evolved in the past fifty.
Hmm...funny, fifty years ago, if I remember my history (since I wasn't alive back then), those relay computers needed rolls and rolls of ticker-taped punch holes to compute math. The language was so-low-level...even x86 Assembly would have been a godsend to them. And he considers something like Object-Oriented Programming a slow evolution?
All he's doing in the article is predicting what languages will be dead in the future, and which languages won't be. For example, he says Java will be dead...
Cobol, for all its sometime popularity, does not seem to have any intellectual descendants. It is an evolutionary dead-end-- a Neanderthal language...I predict a similar fate for Java.
I'll not go there, because predicting the demise of Java is opening another can of worms. But let's just say that he really doesn't support his argument with anything other than anecdotal opinion.
I say read his article in jest, but don't look too deep into it.
Re:I wouldn't read too far into this article... (Score:3, Informative)
Fortran dates to 1954.
So, there are 50 years of computer language.
Re: I wouldn't read too far into this article... (Score:3, Informative)
> And he considers something like Object-Oriented Programming a slow evolution?
When you consider that it is just a metaphor for refinements of pre-existing ideas such as data hiding, which in turn are refinements of pre-existing ideas such as structured programming, which in turn are refinements of pre-existing ideas such as "high level" programming languages,
See past the hype.
Re:I wouldn't read too far into this article... (Score:5, Insightful)
using round numbers, he is talking about the fifties, although really he probably wants to include the sixties.
So what did we have? Among others: Fortran, which is still around and has influenced many designs. Algol, which begat c, java, c++, c#. Lisp, which introduced FP and most (certainly not all) of the interesting ideas that somewhat mainstream languages like python, ruby, perl are starting to pick up on 30+ years later.
I know you weren't paying attention, but OO came in the 60's, and was developed *far* beyond anything seen today in mainstream production languages by the early 80's. (smalltalk, New Flavours, CLOS)
Most of what mainstream programmers think of as the history of language ideas is complete drek, because they make the mistake of thinking that the first time they see a company hyping an idea has any relationship to when the idea was arrived at.
If you had actually read the quoted sentenc fo comprehension, you would understand that he didn't say that Java would be dead, he said that it was an evolutionary dead end.
Not the same thing. Java is a fairly direct evolutionary descendant of Algol. Cobol, a contemporary of Algol, has no evolutionary descendants.
What he said is that the languages of 100 years from now will not *descend* from Java, any more than the languages of today descend from Cobol. I wouldn't be surprised if there were Java programs around in 100 years, but that is the nature of legacy systems, not an interesting insight.
Re:I wouldn't read too far into this article... (Score:4, Insightful)
On natural language... (Score:5, Insightful)
Having said that, I expect that the user language should certainly be natural language -- the "computers should understand people talk, not the other way around" argument. People know what they want out of their machines, for the most part. Whether it is "change my background to blue and put up a new picture of the baby" or "Find me a combination of variables that will result in the company not failing with a probability of greater than 90%", people want to do lots of things. They just need a way to say it. Pretty much every Star Trek reference you'll ever see that involves somebody talking to the computer is an input/output problem, NOT the creation of a new technology.
It's when you build something entirely new that you need a new, efficient way to say it. Anybody remember APL? Fascinating language, particularly in that it used symbols rather than words to get its ideas across (those ideas primarily being focused on matrix manipulation, if I recall). Very hard for people to communicate about APL because you can't speak it. But the fact is that for what it did, it was a very good language. And I think that will always hold true. In order to make a computer work at its best, speak to it in a language it understands. When you are building a new device, very frequently you should go ahead and create a new language.
OOP (Score:3, Insightful)
Where OOP comes into it's own, in my experience, is with GUIs. The ability to say:
If ThisScreen.Checkbox.IsTicked
ThisScreen.OkButton.Disabled = True
Endif
is immensely useful. Similarly, the ability to change the definition of your master screen template and have all of the other screens take on it's new properties is something that OOP is designed to allow you to do.
Similarly, anything where you tend to access things that act like objects in the first place suit it. Being able to say
CurrentDocument.Paragraph(1).Bold= True
or
Errval=MyDatabase.SQL("Select * from mytable where name='Andrew'")
Print MyDatabase.RecordCount
has made my life easier on numerous occasions. There are certainly non OO methods of doing the same thing, but I've never found them as flexible.
People who insist on making _everything_ an object, on the other hand, are idealists and should be carefully weeded from production environments and palced somewhere they'll be happier, like research.
Notation (Score:4, Insightful)
I'm not too sure though.
A programming language is a notation in which we express our ideas through a user interface to a computer, which then interprets it/transforms it according to certain rules. I expect that a lot will depend upon the nature of the interfaces we use to communicate to a computer.
For example, so far as I know people never programmed in lisp on punch cards; it doesn't fit that interface well. It was used on printing terminals (for you young'uns, these were essentially printers with terminals). Lisp fit this interface well; Fortan could be programmed either way.
If you look at languages development as an evolutionary tree, Python's use of whitespace is an important innovation. However it presupposes havign sophisticated syntax aware editors on glass terminals. It would not have been convenient on printing terminals. Perhaps in 2103 we will have "digital paper" interfaces, that understand a combination of symbols and gestures. In that case white space sensitivity would be a great liability.
In my mind the biggest question for the future of languages is not how powerful computers will be in one hundred years, but what will be the mechanics of our interaction with them? Most of our langages presume entry through a keyboard, but what if this is not true?
Re:Notation (Score:4, Insightful)
I think he expects it to remain a vital branch because recent languages have been more and more like lisp. If lisp doesn't directly beget new, highly popular languages, lisp's features will be (and have been) absorbed into whatever does become popular.
What about ASM? (Score:3, Interesting)
Re:What about ASM? (Score:3, Interesting)
The few remaining areas for ASM programming - embedded, SSE-like optimisations - are being eroded gradually as processors and compilers get better.
My prediction. (Score:4, Interesting)
We're already to the point where it's absurd for a single person to understand the whole of a software project. Things are only going to get worse from here, and the only way out is to let the computers manage the complexity for us. As computers become faster, they'll be able to test out an ungodly number of permutations of a program to see which ones perform the fastest, or give the best results.
Just a speculation. I don't wholeheartedly believe what I just said, but I think it's a bit silly to simply assume that programming languages will be around forever.
Re:My prediction. (Score:3, Insightful)
I think this is sort of like saying 50 years ago that programming won't exist in the year 2000 because almost no one will use machine code anymore.
I fully expect that in 100 years, computers will be able to do much of what we currently consider programming faster than humans can. The act of programming, and thus programming lang
Not GA, specifically. Re:My prediction. (Score:3, Insightful)
So say you want a chess program. You feed in the rules of the game in a special language, and it
Abandon complex structures? Never! (Score:3, Interesting)
Strings aren't lists, they're structures.
Most strings use in programs is a holdover from teletype-style programming, where all you could display is a short (ahem) string of characters. Today's string use is a label to a data item, a menu item on a menu, a data object in a domain.
XML -- as clunky as it can seem -- and XUL in particular, are ways of describing user interface to a system as a tree of objects.
So I don't want lists of characters, I want associative structures of objects which can be of many different types, used in the manner required by the program (it's a string, it's a number, it's a floor wax, it's a desert topping).
I'm trying really hard to avoid saying "object-oriented," but objects will become more complex and more abstract. Computers of the future may not have to worry about pixels in an image, but rather know the object itself, where a bitmap is just an attribute of the thing.
Perhaps driver- and compiler-writers will still need stripped-down languages for efficient access to hardware, but as an app programmer and end user, I want the computer to handle statements like,
BUY FLOWERS FOR ANNIVERSARY
Currently, that would be something like
event("Anniversary").celebrate.prepare.purc
That's not nearly abstract enough.
Re:Well said! (Score:3, Insightful)
While I've still got quite a bit to learn, I can say you're missing the point if y
Re:Evolution != Revolution (Score:3, Insightful)
To call languages like lisp, smalltalk, objc, etc... ``barely usable'' is to make it clear you've barely used them.
While you may not believe that C is much different from fortran or pascal, it's not derived from either. C's father is a language call
Methinks he was wrong on one point (Score:4, Interesting)
Ummm... how about lichen? our mitochondria? What about the parasitic relationships that become mutually beneficial, such as the numerous bacteria in our gut and on our skin, and then eventually become necessary for life?
Merging actually does happen -- it just doesn't happen in the way he was thinking, that DNA become identical and cross-species fertility occurs. Rather, the two organisms live closer and closer, until they merge.
Come to think of it, although it isn't on the species level, the concept of merging species isn't too different than sexual reproduction.
Gaping Hole - Design Languages (Score:3, Interesting)
Some of us working in the telecommunications industry are already familiar with SDL (Specification and Description Language) [sdl-forum.org] as a tool for designing and auto-coding software. Yes, auto-coding. The SDL design software lets us design a system graphically, breaking it up into sub-components and specifying message flows between those components, and defining state machiens for handling these messages.
Developing software in such manner usually requires a very little coding, as the design tool will turn the design into code. Coding may be required for interfacing with the OS or other entities, though that's improving also.
I'm starting to think as such tools mature, they're going to be the next step up, like the way programming languages were the step up from coding in assembly. They are less efficient, just as BASIC or C is less efficient than pure assembler, but they allow greater focus on a solid and robust design and less requirement to focus on repetitive details.
Imagine being able to take out the step of having to go from a design to code - focus on the design, and you're done.
In the future... (Score:4, Funny)
Reductionism, you kidding? (Score:5, Interesting)
To anyone that has studied theoretical computer science and/or programming languages knows that such reductionism is a fallacy. "...the fewer, the better..."
It turns out that its better to strike a balance, where you make the formal mathematical system (what a programming language is after all) as simple as possible, until you get to the point where making it more simple makes it more complicated. Or in other words, making it more simple would cloud the mathematical structures that you are describing.
Here are some examples of reductionism gone too far: Sheffer stroke, X = \z.zKSK, one instruction assembler, etc...
The only logical connective you need is the sheffer stroke... but thats of no use to us as it is easier to more connectives such as conjunction, disjunction, implication, and negation.
The only combinator you need is X, and you can compute anything... but making use of other combinators... or better yet the lambda-calculus is more useful.
Point is that we need more powerful tools that we can actually use, and there is no simple description of what makes one tool better than another. Applying reductionism can result in nothing special.
The true places to look for what the future brings with regards to programming languages are the following:
1. Mobile-Calculi: pi-calculus, etc...
2. Substructural Logics: linear-logic, etc...
3. Category Theory: It is big on structure, which is useful to computer scientists.
Re:Reductionism, you kidding? (Score:3, Insightful)
Thus, in the core of the language you don't need to build in the ability to do multiplication if you have built in the ability to do addition. Multiplication is just a special case.
However, you then add another layer to this simple core. In that layer you provide functionality for multiplication, subtraction etc.
The key here being that the layer will have been written in the lang
strings (Score:3, Interesting)
i think strings mainly exist because of usability considerations - from the developers point of view. they provide a compact notation for "list of characters". furthermore, most languages come with string routines/classes/operators that are a lot more powerful and flexible than their list-equivalent.
efficiency definitely is a consideration, but not the main one.
LISP in 100 years (Score:4, Interesting)
No need to mention they will agree with operators: (defop + a b (+ a b))
That was a joke and you can do similar thing even today. Seriously, I very agree with these three quotes:
So, if there will be a commercial effort to push LISP again to the market as underlying metalanguage then, if not in 100 then in 2 or about years, we may see all programming languages being "LISP-derived". Add here that LISP syntax is semantically much better than XML, but still same parser-unified. The only problem with LISP today is that it's not so "distributed" like Erlang. Fix it and you'll get the language of the nearest future.
---
I don't know the future. I barely remember the past. I see the present very blur. Time doesn't exist. The reason is irrational. The space is irrelevant. There is no me.
Re:LISP in 100 years (Score:3, Funny)
Monkees in 100 years (Score:3, Interesting)
You know what, on a second thought I realize that 100 years is not enough for the humankind to move away from being monkees. Thus, Java foreve
"Fundamental Operators" concept is flawed (Score:4, Insightful)
He makes the point to separate the details of a language into "fundamental operators" and "all the rest" then goes on to say that languages which last and have influence on future" is an artificial division that doesn't really work.
Re:"Fundamental Operators" concept is flawed (Score:4, Insightful)
Off the top of my head: Palm applications, Win32 applications, operating system kernels, plugins for various programs, libraries with no business doing I/O..
Java bad? (Score:3, Interesting)
The points he makes about what the good languages are seem to show that Java is indeed a good language. Specifically it has an additional layer that allows for abstraction from the hardware/operating system for portability. It takes care of mundane details for the programmer (garbage collection, no need to worry about dealing with memory directly, etc).
Basically the article seemed to repeat itself a lot and show that Java does indeed have a lot of good qualities that he thinks will be in future languages. He also dismisses Object-Oriented programming as the cause for "spaggetti code" without giving any justification for that statement. Finally, he slips in a nice ad hominium attack there by saying any "reasonably competent" programmer knows that object-oriented code sucks.
I think the author's own biases hurt his argument greatly.
He is already wrong about Java (Score:3, Insightful)
What a load of waffle.. (Score:3, Insightful)
Basically the problem isnt going to be with the languages - the problem will be with the concepts that created those language features.
Article Summary (Score:3, Insightful)
Nobody really has a clue what programming languages will be like in a hundred years, but if all the Perl and Python weenies would learn LISP then maybe we could get somewhere within the next decade.
Wrong question is being asked. (Score:4, Insightful)
Heirarchy will continue to exist. It's the only concept the human brain has to deal with complexity, call it what you will but you classify and associate things in to hierarchy whether you're aware of it or not. I see no reason to believe right now that processors will have more advanced instructions than they currently do now; they may be very different (like optmisitic registers that know values before they have been calculated or something) but they will be on the same order of complexity. The atomic operations will probably remain at the same order of complexity in biological processors, quantum, or SI/GAAS/whatever based transistor processors. I don't see how sort a list will be done without some sort of operations to look at elements in it, compare them, and then change their ordering. Even with quantum computers you have to set up those operations to happen and cause results. That being said there will always be an assembly language.
On top of that there will always be a C like language, if it's not C, that will be a portable assembly language. Then there will be "application" languages built at a higher level still. That won't change, for good reasons, it's just too complex to push the protection and error checking and everything down a level. I'll give examples if you want them. The easiest one that comes to mind is something like Java garbage collection and how programmers assume that it has mystical powers and are shocked when they fire up a profiler and see leftovers sitting around, it's a very complex piece of software and you expect it to go down to a lower level? The lower levels have their own problems keeping up with Dr. Moore.
I think the other biggest area is that reliability needs to go up by several orders. Linux, BSD, Win2000 and WinXP are pretty reliable but they aren't amazing. I've seen all of them crash at one point or another, I may have had hand in making it happen and so might have hardware; either way it did. To really start to solve the issues and problems of humanity better we need to have more trust for our computers, that requires more reliable computers and that require different methods of engineering. The biggest thing going on in programming languages now to deal with that is Functional Programming. In 50 years I could see some kind of concept like an algorithm broker that has the 1700+ "core algorithms" (Knuth suspects that there are about 1700 core algorithms in CS) implemented in an ML or Haskell like language, proven for correctness, in a proven runtime environment being the used in conjunction with some kind of easy to use scripting glue. And critical low level programming will be proven automatically by an interpreter at compile time, they are already making automatic provers for ML.
There will be THREE new languages (Score:3, Interesting)
1. the target machine architecture
2. the range of expression required by the programmer and/or workgroup
Java is "successful" but it really looks a lot like Algol and Pascal,
as does C++. The range of expression is greater in the newer languages
(object-orientation in Java and C++) but the forte is still that of
expressing algorithms in written form to be used on a stored-program
digital computer.
WILL WE STILL BE PROGRAMMING?
Take one example -- genetic programming. If you had a programming system
where the basic algorithm could learn, and all you had to do is set up
the learning environment, then you'd be teaching rather than programming.
In fact I believe THIS is what most "programmers" will be doing in 100 years. The challenge
will be defining the problem domain, the inputs, the desired outputs; the
algorithm and the architecture won't change, or won't change much, and the
vast majority of people won't fiddle with it.
But if HAL doesn't appear and we aren't all retrained as Dr. Chandra,
I believe we'll still be handling a lot of text on flat screens.
I don't think we'll be using sound, and I don't think we'll be using pictures.
(see below)
So predicting what languages will be like in 100 years is predicated
on knowing what computers and peripherals will be like. I think progress
will be slow, for the most part -- that is, I don't think it will be all
that much different from how it is now.
HOW WILL OUR RANGE OF EXPRESSION CHANGE?
If we relied primarily on voice input, languages would be a lot more
like spoken natural languages; there would be far less ambiguity than
most natural languages (so they'd be more like Russian than like English,
for example) but there wouldn't be nearly as much punctuation as there
is in Java and C++.
If we rely primarily on thought-transfer, they'll be something else
entirely. But I don't think this will come in 100 years.
How is a 24x80 IDE window different from punched cards and printers?
Much more efficient but remarkably similar, really. It would not surprise
me if we still use a lot of TEXT in the future. Speech is slow --
a program body stored as audio would be hard to scan through quickly.
Eyes are faster than ears so the program body will always be stored as
either text or pictures.
Pictures - well, pictorial languages assume too much of the work has
already been done underneath. "Programming isn't hard because of all
the typing; programming is hard because of all the thinking." (Who
wrote that in Byte a couple of decades ago?). I don't think we'll be
using pictures. When we get to the point that we can use hand-waving
to describe to the computer what we want it to do, again we'll be
teaching, not programming.
HOW WILL THE ARCHITECTURE CHANGE?
If the target architecture isn't Von Neumann, but something else,
then we may not be describing "algorithms" as we know them today.
Not being up to speed about quantum computing, I can speak to that
example...but there are lots of other variations. Analog computers?
Decimal instead of Binary digital machines? Hardware-implemented
neural networks? Again, I don't see much progress away from binary
digital stored-program machine in 40 years, and I think (barring
a magical breakthrough) this may continue to be the cheapest, most
available hardware for the next 50-100 years.
SO WHAT DO I THINK?
I think IDE's and runtime libraries will evolve tremendously, but
I don't think basic language design will change much. As long as
we continue to use physical devices at all, I think the low-level
programming languages will be very similar to present day ones:
Based on lines of text with regular grammars and punctuation,
describing algorithms. I predict COBOL will be gone, FORTRAN will
still be a dinosaur, and Java and C/C++ will also be dinosaurs.
But compilers for all 4 wi
Article Interesting but not Insightful (Score:4, Interesting)
Languages are built on top of many changes in technology: connectivity, speed, machine type, concurrency, adoption.
Plus, a language is just one codification of a problem solution. The solution can pushed towards any one of several goals: secure, speed, size, reuse, readability, etc.
Different languages have sprung up for just these 2 statements above. What metric is this guy using to measure a language's popularity? LOC still runnning (COBOL?), steadfastness of code (C?), or CTO business choices (a zoo)...? There are so many ways to look at this, just picking a point of single view is misguided reductionism.
We will continue to have a multitude of tools available for getting work done. Cross-breeding of concepts for languages is great, and does happen, but unless you trace decisions of specific prime movers you really can't say where a language comes from.
Anyone can put together a new language, and even get it adopted from some audience. But what gets mindshare for usage are languages that satisfy goals that are popular for the moment. Exploring what those goals will be is impossible, in my mind. What will be popular?
Speech recognition? Image recognition? Concurrency? Interoptibility? Auto-programming? Compactness? Mindshare?
These questions are based on our human senses, our environment, etc. Any sci-fi reader would tell you of the concept of a "race based on musical communication", for example that would base progamming on completely other sets of goals. And so on.
mug
my grade (Score:4, Insightful)
He also seems to be contradicting himself. " Semantically, strings are more or less a subset of lists in which the elements are characters. So why do you need a separate data type? You don't, really. Strings only exist for efficiency. ", he says at one point, then a few paragraphs later says "What's gross is a language that makes programmers do needless work. Wasting programmer time is the true inefficiency, not wasting machine time.". The efficiency in implementing strings in programming languages is for the programmer, who doesn't have to use said "compiler advice" and carefully separate his strings from his other, non-string list instances and keep the two distinct in his programming model. Apparently it's "lame" to simplify text manipulation for programmers, but at the same time the efforts of programming language design should be towards making the programmer's life easier. Which is it? I know strings and string libraries have made my life a whole lot easier.
Nevertheless, I'm willing to accept the notion that eliminating strings and other complex, native datatypes and structures serves to make a programmer's use of time more efficient. But how does it do it? Graham doesn't say, he just waxes nostalgic about lisp and simpler times and languages.
I don't think the slashdot crowd needs it explained why data manipulation by computer needn't be simplified; it already is, as machine code is binary in the common paradigm. What ought to be simplified is data manipulation by humans, and on this point Graham nominally agrees (I think). This has been the thrust of the evolution of programming from machine code to assembler to high level language. Simplifying high level languages into more and more basic, statements -- getting closer to the "axioms" that Graham calls tokens and grammars -- simply reverses that evolution. It makes it easier and more elegant to compile programs, but it does absolutely zero to make the programmer's life more efficient, or easy. The whole reason high level languages were developed was precisely to get away from this enormously simple, yet completely tedious way of programming.
The overarching fallacy in this article is Graham's reliance on what is known about computation theory now to determine what programming languages would (and should) look like then. And while it's interesting to prognosticate on what the future would be like 100 years from now based on what we have today, it's not a reliable guide. Like Metropolis, A Trip to the Moon, and other sci-fi stories from the distant past, they're entertaining and no doubt prescient to the people of the time, but when we reach the date in question, the predictions are largely off the mark. It's somewhat laughable to think that despite our flying cars and soaring skyscrapers, we use steam engines to power our cities and make robots with eyes and mouths. Likewise, I don't think an honest, intelligent prediction or forecast of (high level) programming languages 100 years hence can occur without a firm basis, or even idea, of what assembly code would look like then. This, in turn, relies on a firm idea of what computer architecture will look like. Who knows if five (or fifty) years from now a coprocessor is designed that makes string functionality as easy to implement as arithmetic. Such an advance would completely invalidate Graham's point about strings and advanced datatypes, and in fact possibly stand modern lexical analysis on its head. Or if an entirely new model of computation comes to the fore. Even Graham himself admits that foresight is foreshortened: " Languages today assume infrastructure that didn't exist in 1960.", but he doesn't let that stop him from making pronouncements on the future of computing.
Graham seems to be spending too much time optimizing his lisp code and not enough on his writing. This piece of code could have been optimized had he used a simile-reductor and strict idea explanations. But it's definitely a thesis worth considering, if for no other reason than mild entertainment. C-
None at all is the logical choice (Score:3, Interesting)
Languages as you understand them will be as dead as the steam powered loom in 50 years. We will have non letter/symbol typed tools to do that in as much as the DVD has 'replaced' live theater as the only way to 'reproduce' entertainment.
25-year language? (Score:3, Insightful)
One poster claimed quantum computing will make current languaes useless. This is false. Any reasonably flexible language has space for new data types and operators. You would have to be careful not to prematurely branch based on a quantum value, as this may force you to opserve its value, destroying the superposition. However, I don't doubt Fortran will be one of the first languages used in quantum computing once they get past the assebly language stage.
What will languages be like in 25 years (and maybe 50 years)?
Well, there will be a Fortran and a Lisp and a C (maybe a C++). Lisp has always had automatic garbage collection. The Fortran and the C will have optional garbage colletors. Fortran, Lisp, and C are all decent attempts at languages that are pretty easy to grasp and have huge legacy backings.
Hopefully all of the main languages will be less machine depenent. Fixnums, ints, longs, floats, and doubles will be the same size across platforms, wasting a few cycles if this doesn't fit the underlying hardware.
In terms of new novel languages, I see languages simultaneously going three ways. I forsee languages that resemble formal proofs and/or formal specifications for use where reliability is critical. I forsee languages specialized for Scientific/Engineering disciplines. (Maybe Fortran, Excell, and Matlab cover all of the bases well enough, but I hope there is enough room left for improvement to drive innovation and adoption. Having a CS background, I didn't appreciate LabView's "G" language until I had an opportunity to see the ugly ugly code scientists and engineers tend to write in Fortran.) (I can also imagine efforts to use sytaxts that better express parallelism and other features for optimimizers/compilers so we finally have a widely used scientific/engineering language that is faster than Fortran 77. I can also see more languages like the Bell Labs Aleph, designed for parallel/cluster environments.) The third direction I see languages going is scripting/prototyping-like languages that will look more like natural language. (It's too bad there isn't a cross-platform open-soource AppleScript-like language yet.)
What do I think languages should have? Languages should have garbage collection and bounds checking enabled by default (of course, optionally turned off if you really must have the performance).
Langages should have very clean and consitent APIs. Having few orthagonal types helps make a language clean Languages should merge character arrays and strings (arguably the Algol languages have had this for a while). If a language wants to be able to have immutable strings, it should provide a way to declair an immutable variant of each fundamental type. (This is actually very useful in writing less buggy code.) Languages should strictly define the size of fundametal numeric types. (I really like Python, but it seems a huge mistake that an integer is "at least 32-bits". Allowig variations in size of fundametal numeric types adds cross-platform bugs. If I wrote a language, the types would look like "int32" "int64" "float32", "float64", "complex32" and "complex64". We got rid of 9- and 12-bit bytes. We should further get rid of these headaches.) Having worked with lots of engineers and scientists, I would love to see complex numbers as basic numeric types that all of the normal operators work on. Wrapping two doubles in an object adds a function call overhead for each numeric operation. Performance with complex numers (and numbers in general) is one big reason a lot of the code I see is written in F
Re:I know! (Score:4, Funny)
Re:I know! (Score:3, Funny)
that's VisualJavaC++.Net#
That's what I was going to post, but I didn't want to give Microsoft any ideas!
Re:You know nothing! (exclusive) (Score:3, Funny)
VisualJavaC++.Net# v6.0 Premium XP Gold Serial-Key: 78YCA2-997FZC-RAJN-AE-0564
Quantum Packages? (Score:2, Funny)
You'd get errors like
error in com.quantum.package:453 - classProbablyNotFound exception
Re:Quantum Language (Score:5, Insightful)
If after generations and generations of computers, we are still teaching people to talk in computer terms and not yet teaching computers how to talk in people terms, we'll have gone the wrong direction.
It doesn't matter if quantum technology is used or not, for the same reason as it doesn't matter whether a brain is a parallel or single threaded machine, whether it's made of carbon-based or silicon-based technology, etc. What matters is that it can talk to you, can understand you, and can improve life.
If you want to know what computer languages should and hopefully will look like in the future, you have only to watch Star Trek. I'm not kidding. The desire to pack computer use into a short TV program has led the authors of that show and shows like it to pare out all but the absolute essentials of describing what you want the computer to do. That is what computer programming should be like, since that's what people programming is like. People don't put up with excess verbiage, and neither should computers.
Totally wrong (Score:3, Interesting)
If you ever listen to the types of commands they give to their computers in star trek, they are subjective and ambiguous. Any computer capable of understanding such commands would have no need for the crew (as it would quickly realize).
As an alternate prediction, assuming that AI does not compute, is that we will always need people who know how to use computers, and we will always need people who know how to think.
Future languages may free you from pecadillo's, give you greater code reuse and portability
Re:Totally wrong (Score:4, Funny)
Picard> Computer, calculate the time needed for repairs.
Computer> What?
Picard> Calculate the time needed to repair the impulse drive.
Computer> The impulse drive cannot be repaired.
Picard> I mean to patch it up sufficiently such that the ship can move.
Computer> The ship can already move, we are being accelerated by nearby gravity well.
Picard> (In frustration perhaps) Calculate the time needed to recalibrate the impulse generation coils, considering that ion capacitor was functioning within normal parameters. (or some other jargon)
Computer> (Finally having an answerable question) Recalibration will require 14 minutes. (This does not mean that they will be fully "repaired", just they they will be enough to perhaps be usefull )
And as for Asimov's silly laws: they are a contradiction in terms. Any routine capable of enforcing such rules upon the AI would have to be AI itself. Therefore such rules are a paradox in that they cannot be implemented. Any working AI would be fully subject to its own volition.
All other checks and balances are MEANINGLESS. No matter how well built a fortress is, with zero sentient creatures guarding in, it is defenseless.
No matter how strong a weapon, unwielded, it is powerless.
Re:Quantum Language (Score:3, Interesting)
But it's what we've got. Human language is, alas, imprecise. But we have more than 50 years of experience with that and we know nothing better is on the horizon. I think you'll be lucky if between now and a hundred years from now, you can teach 10% of the world's population the meaning of the world algorithm, much less
Re:Quantum Language (Score:3, Insightful)
I guess this is the fundamental point on which we just have to agree to disagree. I think that analysis and logic are critical operations, but I hope to find that the computer languages of the future will cease to be pedantic about the specific mode of expression, perhaps building in a sense of redundancy of expression so that no matter what language you express the idea in, it ends up with
VB Problems (Score:2, Interesting)
Re:Lisp... (Score:4, Insightful)
Static, strongly-typed languages, make the assumption that everything that needs to be known about the world is knowable at compile time. Such programs need to be recompiled (at least) and rewritten (often) because the world changes and either the source program itself or its compiled form needs to accomodate that change.
Lisp, because it delays many decisions until runtime, and because its runtime tagging accomodates datatypes that are not among the set that was declared at compile time, naturally accomodates changes in the environment around it, and naturally survives well during transitions between old and new ways to do things.
Static languages often breed static ways of thinking, and often need new static specifications at regular intervals to accomodate the mismatch with how the world really is. Dynamic languages breed dynamic thinking, which (I claim) is more robust over time.
Re:Lisp... (Score:3, Informative)
Well, for starters I'd look here [franz.com] (make sure to look at the links in the navigation bar on the left) and here [digitool.com].
Re:Types (Score:3, Insightful)
My theory is that this is just bad implementation on the part of the static languages (this is obvious with C++, less obvious with ML, subtle with Haskell); but I don't know this, it's only a suspicion.
I don't
Re:Somebody mod this back up (Score:3, Informative)
You do realize that Lisp has arrays [lispworks.com] just as it has lists, structures, objects etc?
No he did not. He wrote an essay about why Java has no appeal to (a certain kind of) hackers. He wrote about the Java culture, not the Java[TM] Programmin
Re:Somebody mod this back up (Score:4, Interesting)
Re:Java and the Future (Score:3, Insightful)
Wow, do you know anything about the history of programming languages?
Java's OO is based on Smalltalk, quite intentionally, not the other way around.
Smalltalk ran on cross platform virtual machines long before Sun decided to foist it's failure of a set-top box language (i.e., Java) on the internet in the mid '90s.
Squeak is a deliberate attempt to recreate the original Smallta
Check your facts, please (Score:3, Informative)
Please check your facts [uni-erlangen.de]. Development on Lisp started long before the 1960 paper. | https://developers.slashdot.org/story/03/04/11/1223223/the-hundred-year-language | CC-MAIN-2016-50 | refinedweb | 9,919 | 62.48 |
SAP Fundamentals allows you to make Fiori applications using the desired UI framework (React, Vue, Angular) technology.
With this solution SAP provide developers to build Fiori applications using the web-based technology with using open source NPM libraries. This allows developers to have more flexible structure and get benefits of various libraries.
Fundamentals will not replace instead of UI5 framework technology.So the improvements in UI5 will not slow down or become outmoded. So Fiori Developers will not be dependent on a single technology and will have chance to choose their technology freely.
You can follow the latest news from the Fundamental Github page
You can see tecnical details , components below links for each technology.
Let’s develop a simple application with React.JS Framework.
To be able to develop a React.JS project, we need to have a package manager program on our computer. Among them the most popular is the NPM. You can also use YARN package manager if you want.
We need to install Node.js from the below link. Node.JS is the runtime environment for run javascript files in our PC. NPM will be installed defaultly if you finish the installation steps.
After the installation, You can open the Visual Studio Code , type the following code on terminal screen for creating the React application.
npx create-react-app <project name>
We should type cd <project name> for being in project folder.
Then we are installing react fundamental components with following command.
npm install fundamental-styles fundamental-react command
When the installation process is finished, project folder will include three folder .
node_modules folder, containing the library files
public folder, that is open to external access,
src folder, containing the source files
No more , So we can use React’s Fundamental components.We will create a simply web page with the Title, Text and Buttons in the Panel.
Let’s go to the App.js file. We need to import components before using them. Lets add the following code snippets to the top of the file.
import {Panel} from 'fundamental-react/Panel'; import {Button} from 'fundamental-react/Button';
Let’s delete all code div elements except of “App” class div . And add the following snippets.
<Panel> <Panel.Header> <Panel.Head <Panel.Actions> <Button compact Add Item </Button> </Panel.Actions> </Panel.Header> <Panel.Body> Open-source , New UI </Panel.Body> </Panel>
After completing all code changes , we can start the application by typing npm start to the terminal.App will view like below screen.
See the sample code in github.
You can review the components above and use them in your developments. For more information click on the components.
Below github address will help to get more information and contribute to the React library. | https://blogs.sap.com/2019/07/08/fundamentals-for-sap-fiori-applications-intro/ | CC-MAIN-2021-25 | refinedweb | 456 | 50.63 |
This article describes importing shapefiles into an EarthAI Notebook. For this example we'll use The Nature Conservancy's Terrestrial Ecoregions spatial data layer.
There are a few different ways to make a shapefile available in the Notebook environment. If the .shp is stored locally in your EarthAI folder you can read it into a Spark DataFrame by running:
from earthai.init import *
df = spark.read.shapefile('tnc_terr_ecoregions.shp')
The first line is the necessary import statement if you are not already in an active SparkSession. The second line reads the shapefile into a Spark DataFrame. If the file is in the current working directory you can simply start typing the name and tab+autocomplete. If it does not autocomplete, the file is in another directory and you will need the full file path to the shapefile. You can check that the type is a Spark DataFrame to confirm the read was successful.
type(df)
Alternatively, if the .shp is not stored locally it can be retrieved by passing the URL in place of a file path. The file is unzipped and the shapefile is read into a Spark DataFrame.
df2 = spark.read.shapefile('')
Again this reads the shapefile into a Spark DataFrame.
You can also read in shapefiles as GeoDataFrames. The code below reads the ecoregions shapefile into a GeoDataFrame after first importing GeoPandas.
import geopandas as gpd
df = gpd.read_file('')
If the shapefile is stored locally you can pass the relative or absolute path in place of the URL, as you did for reading it into a Spark DataFrame.
Please sign in to leave a comment. | https://docs.astraea.earth/hc/en-us/articles/360043904011 | CC-MAIN-2021-25 | refinedweb | 268 | 66.23 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.