199,113 Archived Topics
Remove Filter ![]() | |
What are the differences between NP vs NP-Complete vs NP-Hard ? I am aware of many resources all over the web. I'd like to read your explanations to undrestand better | |
Hi I am trying to create a class so I can use buttons globally throughout my code but I am doing something wrong and I can't figure it out. My Global class code. using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Threading.Tasks; using … | |
Hi. i need to build an expression tree from a string and i dont get how to do it. for exapmle: str[20]="( (2 + 5) * (8 / 2))";  can some one help me? thanks. | |
I'm making a program that takes the last letter and second to last letter of a name and displays a formatted version in front of the name. I'm passing an array to hold all the names and it seems to work properly, but it displays null before each output. Why … | |
i use the below code to create file in android but the files are not created when i use android version 4.x but when i use version like 2.x the code working fine and the files are created File path = new File( Environment.getExternalStorageDirectory()+"/FullDuplexCall/"); path.mkdirs(); try { sendfile = File.createTempFile("sendfile", … | |
hello dears i tray code the button which can send SMS from my server (i'm ethiotelecom employer) to any cell phone but the SMS faild always. pls can you help me? | |
#!/usr/bin/python import Evaluar from pylab import * from numpy import * def biseccion(a, b, TOL, N): Evaluar.dicc_seguro['x']=a fa = eval(Evaluar.funcion, {"__builtins__":None}, Evaluar.dicc_seguro) vectorx = zeros(N, Float64) vectory = zeros(N, Float64) i = 1 while i<=N : p = (a+b)/2.0 vectorx[i-1] = p Evaluar.dicc_seguro['x']=p fp = eval(Evaluar.funcion, {"__builtins__":None}, Evaluar.dicc_seguro) vectory[i-1]=fp if … | |
this assignment here was my take home assignment. I am kinda doing it over just to see and know where i went wrong with. it is either my codes wrong somewhere but am not getting the required output. I had to do two methods along with two arrays. dont know … | |
Hello!!! I am a beginner to C++ and linked list and searching algorithm really made me confused. There are 26 errors (which caused by pointer ofc). Can anyone give me idea how to fix these errors??? #include<string> #include<cstdlib> #include<iostream> #include<malloc.h> #include<fstream> #include<time.h> #include<conio.h> using namespace std; #define SIZE 10 class … | |
Hi I am trying to move JTabbedPane down below top panel.I want it where the bottom panel begin.Thanks. import java.awt.*; import javax.swing.*; public class GridBagLayoutTest { JPanel bottomPanel; JPanel topPanel; public GridBagLayoutTest() { JFrame frame = new JFrame("GridBag Layout Test"); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.setLocationByPlatform(true); JTabbedPane tabbed=new JTabbedPane(); tabbed.add(bottomPanel,"One Way"); tabbed.setBounds(12, 200, 20, … | |
Please can someone help me write a simple password program for my program which prints out in stars(*).Thank you. | |
Hello guys can anyone please help me in a problem relating to file. The problem is that I want to use `fgets` on a c file from another c file and increment a the counter every time to get the number of lines and I also want to put the … | |
i have following code @model EMS1.Models.UsersViewModel @{ ViewBag.Title = "List of users"; var grid = new WebGrid(source: Model.users, canPage: true, rowsPerPage: 10); grid.Pager(WebGridPagerModes.All); } @{ ViewBag.Title = "IndexViewModel"; } <script src="@Url.Content("~/Scripts/jquery-1.6.1.min.js")" type="text/javascript"></script> <script src="@Url.Content("~/Scripts/jquery.validate.js")" type="text/javascript"></script> <script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.js")" type="text/javascript"></script> <h2>Grid</h2> <style type="text/css"> .table { margin: 4px; border-collapse: collapse; width: 300px; } … | |
I am trying to experiment with the whole idea of creating two text files then write to one of them, rename the second file with the first file and then deleting the first file. I have a school project where i need to apply this concept. So, before i actually … | |
I have a question is there any possibility for maken a script that you can see if computers are on in your network when you run the script for ex. ./ping.sh 54 62 62 , a script when you give as argument the last digit of the ip adres of … | |
Hello i'm using visual studio 2010 express. I'm beginner. I'm searching how to design a button and to program it ? Thanks for any help | |
So, I'm working on an assignment. It involves a read-in text file and the program itself. When I run it I get what my teacher would call "garbage" in the output. Here is the info from the .txt: Mike 1200 John 350 Jen 1500 Tara 700 Michelle 2000 Kevin 500 … | |
![]() | I have a 'User' model holding some information like username password etc. After installing swingtime I was hoping to correlate its 'Event' model with my 'User' model so I can add events for every individual user. The thing is that in order to do that I need to have a … ![]() |
Hi all, Suppose if I write two programs of same functionality but with different methods and want to measure the run time efficiency how do i know? I mean to say i want to measure the run time of each code how do i do it? Should i check the … | |
pls can i get a code for the following example 1 ** 234 **** 56789 ****** | |
hello I have an application run in php with mysql database that shows me a list of people in different services it occupies. I would like to make a menu that is based on the clicked service shows me the list of persons who holds this service and each new … | |
I wrote a program for converting a file from PPM format to ASCII art. Every pixel of the input image is converted to greyscale by calculating the average of red green and blue values ((red + green +blue)/3). The upgrade of the basic version is that I calculate the average … | |
import evaluar from pylab import * from numpy import * def puntofijo(po,TOL, N): vectorx = zeros (N, Float64) vectory = zeros (N, Float64) i = 1 while i<=N : vectorx[i-1] = po Evaluar.dicc_seguro['x']=po fp = eval(Evaluar.funcion, {"__builtins__":None}, Evaluar.dicc_seguro) vectory[i-1]=fp if fabs(po-fp): print "La raiz buscada es: ",po, "con", i-1, "iteraciones" … | |
im new to java and this is my first assignment can anyone help me solving it: compile the class final grades, based on the students’ scores obtained in the classwork, mid-term, and final exams. According to the course syllabus, the classwork accounts for 65%, the mid-term exam accounts for 15% … | |
I notice that my PHP code contain special numbers (e.g. _5b9652a96785) representing variables: <?php include_once('../include/config.php');include_once('../class/db.php');if (isset($_POST["points"])) {$_5420457f97cc = json_decode(stripslashes($_POST["points"]), true);$_a095ff903bcc = trim($_5420457f97cc["itemName"]);$_58f60403479c = trim($_5420457f97cc["itemCost"]);$_bb2bde3e818f = trim($_5420457f97cc["itemPrice"]);$_5b9652a96785 = $_5420457f97cc["itemUnit"];$_03d9de238649 = $_5420457f97cc["itemCategory"];$_22f632d073d5 = $_5420457f97cc["ingredientArray"];$_83647d4cbbd0 = new dbPdoMysql;$_6445f036fed3 = $_83647d4cbbd0->dbInsertItem($_a095ff903bcc,$_5b9652a96785,$_03d9de238649,$_58f60403479c,$_bb2bde3e818f, $_22f632d073d5);if ($_6445f036fed3 == true){echo "true";}else{echo "false";}}else{}?> What does the special numbers mean and … | |
Difference Between general properties and auto implementation properties? | |
please How can i write a program that user will input the number of question he want and the question will be displayed at random from a group of question using c#. | |
javac Cannot find my Example.java file after saving it in c:\program..\java..\bin\!! i am using win 7 (64 bit). Following points are so confusing.. 1. **Even i cannot** see the file in that directory form window!! 2. If i want to copy it 2nd time, windows ask me to **"overwrit"**. (Means: … | |
Trying to insert both of these arrays of random quotes on the same page so that both show at the same time. I realize I have to rename some of the elements within, but apparently I have no clue which. I've tried giving each rannum, ShowText, and RndText a number … | |
my project consists of 6 files with .py. The first is the main project file, which I called Metodos.py and whose code is: #!/usr/bin/python # coding: latin-1 #import os, sys import Menu from numpy import * Menu.elmenu() Let's see the code Menu.py file: #!/usr/bin/python # coding: latin-1 from math import … | |
Hi, In a representative table, I have fields, like, id, mark_id, rep_id rep_name, father name,etc, In this table, rep_id field is empty, And in rep_area table, the fields are like id, rep_id, dist_id,etc, in this table, rep_id has values. While editing the representative form i want to display rep_id from … | |
Hello i am using WAMP server and the audio player doesnt show up This is the code <audio controls preload="metadata"> <p><label>Error: Your browser does not support the audio element. Install the latest version. If you are using Safari you must install Quicktime.</label></p> <source src="<?php echo $base_url.'uploads/audios/143154310611.mp3';?>" type="audio/mp3" /> <source src="<?php … | |
Above code works Perfectly for single textbox, Thanks for this code. but If in the form there are many textbox and i want to use same code for all, according to this code we have to create may procedure this is not goodd, so how can i use same code … | |
Hi there, I' ve got some data in my database and I' m using PHP to fetch it and would like to transport it to client side via JSON. The problem that I'm facing is the folowing: I have a timeline which was built in html and css and I … | |
Hi all, I need some help with my code, because I have a bit of trouble with using the `cur.execute` in the loops. When I try this: for pos_X, pos_Y, prog_id, prog_width in zip(positions_X, positions_Y, programs_id, program_width): cur.execute('SELECT button_ids, button_width FROM buttons where button_ids=?', [prog_id)) if int(pos_X) == 375: if … | |
I have to do this with "for" and "while" loop in c++ but no idea how print all numbers between 10000 and 100 which are devisible with 5 and 9 but not with 2 any help suggestion advice or anything is needed urgently this is too complicated for me heelp | |
i've made the game Othello in java and i need a way to display to the player, the move the computer did. i can't just return a-6 or d-5 because the size of the board can be changed. anyone has a way? thank you in advance :) | |
HELLO i would like to ask that fetchAll() is good choice to retrieve all user message from database or i should use while loop? I asked this question because i worry about internet traffic.. | |
I have a project to create a simple polling system but my program is not working properly. The result the program is giving is not proper and dont know where the problem lies. can u guys help me out with this. U can see the function i've created to calculate … | |
Hello All, My old computer crashed. I installed XAMMP on my new computer. My old PHP files don't run. I learned that the reason is that register_globals feature has been deprecated and is now permanently Off by default. My old files were written in a 'register_globals=On' environment. I understand that … | |
Do we have any TDD experts here? I have some questions but need an expert. | |
i am failing to link v.b 6.1 program and database. it keeps posting the error "syntax error in FROM clause". how do i make it work because its the forth time i have restarted the project | |
I created project, If It Run from Vb.Net program its works fine, Then Create "Setup" Files and Installed it, When Run "Exe" file, there is error like this, From my Project I want to read this file, (Text File) If I Install this Out of "Program Files" folder, then its … | |
Hello, I am build up POPUP Box for the warrning, reference link [Click Here](http://www.pcattention.com/) That can be supported for all the browser Safari, Chrome, IE, Mozila. I have RND for that but not given exactly solution. Can suggest me something for that. Thanks. | |
Hello, I have a GUI with a timer... but when I put too many lines of code inside the timer method, the GUI lags. private void timer_tick(object sender, EventArgs e) { ... } How could I resolve this problem? I know there are 3 types of timer... Do I use … | |
I have been programming in lisp for a while, not as a main language. But i've gotten pretty decent at it. But I was wondering about if it was a legacy language or not. | |
![]() | Hi I found this code: <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> <script> function enterAsTab() { var keyPressed = event.keyCode; // get the Key that is pressed if (keyPressed == 13) { //case the KeyPressed is the [Enter] var inputs = $('input'); // storage a array of Inputs var a = inputs.index(document.activeElement); //get the Index … |
Hi. There is a textarea in my page. I type a text in the textare and then in the script there is: $text = nl2br(htmlentities($_POST['text'])); Now what is the problem? When i type: `I'm fine.` It will be sent to db and will be printed, in both place as: `I'm … ![]() | |
Hello All, I'm trying to write a simple html editor that will highlight tags, and it does, but if the user types the caret jumps to the very end of the document, how can I stop this from happening? here's my code: [CODE=java] import javax.swing.*; /** * Main frame for … |
The End.