How to find the Nth largest node in a BST?
Do I keep a count variable while doing In Order Traversal of a BST? Return the element when the count = N???
i asked to make a website to view images and manage it's actions like max, min, autofit,.....
(some thing like picasa but as a web application )
what is the suitable tool for that. JSF, JBoos Seam, dojo, digit ?
and if any reference to enhance my skills on that branch will be appreciated.
How do i configure selenium WebDriver.I have automated test cases using Selenium.Now i need to automate upload and download of a file.So i have to automate using WebDriver.I had added webdriver-common-0.9.7376.jar.Now how do i instantiate for Internet Explorer?
Am just decalring variable and using driver
private static WebDriver driver;
driver.findElement(By.id(upload)).sendKeys("file to be upload");
Is this correct?
I'm told to create template of function , that will take 4 arguments :
pointer
reference
pointer to array
pointer to function
How to perform this task ? I was trying :
template<typename TYPE> TYPE biggest(TYPE *L, TYPE $M, TYPE *K[], TYPE *O())
{
}
but it is wrong.
I have string value and Type of some variable (For example int and "32" or bool and true). My type is primitive type. Can I parse string to my type in one line?
I have a big project and I changed the name of 1st form from "Form1" to "WebBrowser", now I It gives me following error.
The type or namespace 'Form1' could not be found(are you missing a using directive or an assembly reference?)
cannot even Change the name back to Form1. it says cannot find WebBrowser.cs on disk its is renamed or deleted from the disk. What I should do, I have a submission tomorrow.
Thanks
I don't understand Access Modifiers in OOP. Why do we make for example in Java instance variables private and then use public getter and setter methods to access them? I mean what's the reasoning/logic behind this?
You still get to the instance variable but why use setter and getter methods when you can just make your variables public?
please excuse my ignorance as I am simply trying to understand why?
Thank you in advance. ;-)
I have a template variable, c.is_friend, that I would like to use to determine whether or not a class is applied. For example:
if c.is_friend is True
<a href="#" class="friend">link</a>
if c.is_friend is False
<a href="#">link</a>
Is there some way to do this inline, like:
<a href="#" ${if c.is_friend is True}class="friend"{/if}>link</a>
Or something like that?
I need to realize a complex if-elif-else statement in Python but I don't get it working.
The elif line I need has to check a variable for this conditions:
80, 443 or 1024-65535 inclusive
I tried
if
...
# several checks
...
elif (var1 > 65535) or ((var1 < 1024) and (var1 != 80) and (var1 != 443)):
# fail
else
...
what would be the shortest way to write this?
if(strpos($haystack, $needle)!==false){
$len = strpos($haystack, $needle)+strlen($needle);
}else{
$len = 0;
}
I remember that I saw some shortcut somewhere for this that checked and set a variable at the same time.
Hi, I'm using ASP.Net and whenever I create a script file or try to include a script file like jQuery they aren't working. I am doing just a regular localhost server and none of the scripts are working. Upon further examination using firebug I look at whats being referenced in those scripts and it shows html code for a 404 error. I know the scripts and files are there and I can navigate directly to them in the browser but for some reason I can't reference them in my page.
Here is a screenshot:
I want to add quartz scheduling to an ASP.NET application.
It will be used to send queued up emails.
What are the pros and cons of running quartz.net as windows service vs embedded.
My main concern is how Quartz.NET in embedded mode handles variable number of worker processes in IIS.
I read about NSLocaleCurrencySymbol, but where would I find the variable used to determine the "number of decimal places" used in a country's currency?
I.E. In the USA, it's common to see dollar amounts written with 2 decimal places: $1.23
What about many other countries?
Thanks.
I have a comment model, I've seen examples of using @comment, :comment, comment to reference for the object in MVC? how do I know which is which? Is there a distinction?
Did Spring abandon YAML to use as an alternative to .properties / .xml because of:
[Spring Developer]: ...YAML was considered, but we thought that counting whitespace significant was a support nightmare in the making... [reference from spring forum]
I am confident YAML makes a lot of sense for properties, and I am using it currently on the project, but have difficulties to inject properties in a
<property name="productName" value="${client.product.name}" />
fashion.
Anything I am missing, or I should create a custom YamlPropertyPlaceholderConfigurer ?
Thank you,
/Anatoly
For those of us who use standard shared hosting packages, such as GoDaddy or Network Solutions, how do you handle datetime conversions when your hosting server (PHP) and MySQL server are in different time zones?
Also, does anybody have some best practice advice for determining what time zone a visitor to your site is in and manipulating a datetime variable appropriately?
I have asp.net mvc 2 application.
Now I'm reimplementing it for working with Ninject. All is fine except one thing: where should I store Ninject.dll??
I've created lib directory inside my appdir and made reference to lib/Ninject.dll.
But may be there are some general conventions on how to act in such cases?
How do you access variables which are defined in an included file?
# inc.rb
foo = "bar";
# main.rb
require 'inc.rb'
puts foo
# NameError: undefined local variable or method `foo' for main:Object
Sub FindAncestor(Of TParent, reference As DependencyObject) As TParent
'find the parent ListBox container
End Sub
'Usage
Sub Handle(lbi As ListBoxItem)
Dim lb = GetListBox(lbi)
End Sub
I have a button in a ListBoxItem datatemplate, I want in the handler of the button to access the parent ListBox (this is the way I want to access it, since it's all nested in other DataTemplates, ItemsControls and stuff).
Hello, I'm using boost singleton from thread/detail. There is in manual, that constructor should have signlature: boost::restricted. But I can't find any reference for this type in boost library. Why do I need in this and where I can find it?
Hi,
we want to use Unity for IOC.
All i've seen is the implementation that there is one global static service which holds a reference to the Unity container, which registers all interface/class combinations and every class asks that object: give me an implementation for Ithis or IThat.
Frequently i see a response that this pattern is not good because it leads to a dependency from ALL classes to this service.
But what i don't see often, is: what is the alternative way?
Michel
I just made this demo extracting out what I'm trying to accomplish:
Autosize Main Content Area
I want the pink/yellow area to act according to these rules:
Minimum height is the size of its content (which is variable) IF content size is smaller than viewport size
Otherwise minimum height is such that it adjusts to fill the window.
Checking out the source to that demo, what am I missing? I feel like this is a pretty easy case that shouldn't require javascript.
Any ideas?
Is it right that the procedure of using log4j looks like this:
1) put a .properties file somewhere in a project folder
2) in an initialization method, that runs only once, invoke
PropertyConfigurator.configure("path_to_file");
3) in every method we need to use logger we define a static logger variable and simply
invoke getLogger(class)
I'm asking you this: what if the initialization module is not defined?
Where to put "log4j.properties" file so that we wouldn't need to invoke propertyconfigurator.configure at all,
or if it's not possible,
is it ok to invoke PropertyConfigurator.configure("path_to_file") in every method that uses a logger?