I'm VERY new and I need help removing some whitespaces between a string and a input(?)? Ask Programming |
- I'm VERY new and I need help removing some whitespaces between a string and a input(?)?
- How can I implement this type of Button in Flutter?
- Simplest way to print columns of data in C
- How do I populate a 2d boolean array with a random 50% chance of being true then read the x and y position of every true and put that into another array?
- Beginners question i need help with
- What is the typed array in JavaScript?
- Help putting into words what i need to do.
- How could I shorten this code? (C)
- How do I generate 1 number in python inside if condition:
- Bluetooth Mouse App Questions
- What does char - '0' mean? (C)
- Help with string slicing.
- I have a strong feeling of age discrimination at job interviews in UK. Is that common?
- What is your use case for parsers in your job or private projects (except as learning experience)? Handwritten or using parser-generators?
- Why architecture matters in terms of programming?
- Can someone help me with flutter fcm integration for background messages?
- How do I handle exceptions in a website? if i caught an exception how should i cancell the whole function stack?
- Help please - I'm clueless and want to make a selection tool that includes pictures so my students can still play their favourite game?
- How would you represent a tree like structure in assembly language?
- Is it easy to make an AI bot for a game that acts like human or has skills very similar to a human?
- About copyrighted pictures...
- C# to Spawn a Python Process
- How would I classify strings into categories based on fuzzy matching?
I'm VERY new and I need help removing some whitespaces between a string and a input(?)? Posted: 18 Sep 2020 04:00 PM PDT This is a part of my code: Print(item_quantity , item_name , '@ $' , ('{:.2f}' .format(item_price)), '= $' , ('{:.2f}' .format(first_total))) This is the current output (with whitespaces between the dollar sign and the numbers): 5 apples @ $ 1.00 = $ 5.00 And this is what I'd want (no whitespaces between the numbers and dollar sign, but kept everywhere else): 5 apples @ $1.00 = $5.00 Edit: im using Python [link] [comments] |
How can I implement this type of Button in Flutter? Posted: 18 Sep 2020 09:05 AM PDT I tried various other things like FAB Circular menu. But I wasn't able to achieve it. Any help is appreciated. [link] [comments] |
Simplest way to print columns of data in C Posted: 18 Sep 2020 10:36 PM PDT I have a C program where I will be iteratively collecting 2 dimensional data. I'm going into each iteration (of 12) with a randomly generated number (of 4) representing "donut type". I will use donut type to request a donut which is given as a positive integer identifying that donut. So that's 12 donuts across 4 types randomly distributed, collected from a 12 cycle loop. I want to print the integer data like this I suppose I could head into the loop with a 2 dimensional integer array and 4 index tracking variables and fill the array throughout the iteration. Then iterate vertically through the 2D array while there is at least one non zero value in the row. At each iteration I would somehow build the row-string for the given values and print it out but not sure how yet... Is this the right path or am I reinventing the wheel? [link] [comments] |
Posted: 18 Sep 2020 09:58 PM PDT I have tried to make a part of my program populate a 2d array with boolean values (default 50% chance of being true) then read all true values, putting the sort of x and y positions into either two different arrays or another 2d array but haven't had much success. Rows and columns are by default 16 but you can change it to whatever size. The code I currently have: bool[,] b_cells = new bool[rows + 1, columns + 1]; int[] x_cells = new int[rows + 1]; int[] y_cells = new int[columns + 1]; Random generator = new Random(); double number; for (int i = 0; i < rows; i++) { for (int j = 0; j < columns; j++) { number = generator.Next(100); if (number < 50) { b_cells[i, j] = true; } else { b_cells[i, j] = false; } if (b_cells[0, j].Equals(true)) { x_cells[i] = j; y_cells[j] = i; } } } Any help would be appreciated, Thanks! [link] [comments] |
Beginners question i need help with Posted: 18 Sep 2020 05:56 PM PDT Write C++ program to print the value of a, b , c after each statement. Suppose a , b, and c are int variables and a=7 and b=2. What value is assigned to each variable after each statement executes? a = ++b +5; c = a+b--+1; b= (a++) - (--c); [link] [comments] |
What is the typed array in JavaScript? Posted: 18 Sep 2020 08:11 PM PDT |
Help putting into words what i need to do. Posted: 18 Sep 2020 07:24 PM PDT Hello all, first time póster here. I need to find pairs whose greater como divider (GCD) =1 in an array. That part i have it figured out. My problem is that i dont need to compare the elements again because they are already paired (order doesnt matter). Right now im using 2 for loops, 1 to select the starting element and another to cycle through from that point till the end of the array. I cant figure out a way to skip the indexes that i already used. Maybe someone can point me in the right direction, i would be grateful. Thanks! [link] [comments] |
How could I shorten this code? (C) Posted: 18 Sep 2020 07:11 PM PDT I'm just getting started with programming. I chose C and I made a simple program that outputs the number pi with the amount of places after the decimal entered by the user. I placed a limit to 10 decimal places, so I had to use 10 if statements to complete this. How could I simplify it? Here's the code: https://pastebin.com/FxvsZ1qP Reason I'm asking is just so I can get better at writing clean code from the beginning when possible. [link] [comments] |
How do I generate 1 number in python inside if condition: Posted: 18 Sep 2020 05:45 PM PDT That is If ...... condition.... A= [1] but I want a to keep generating 1 as long as the condition satisfies with using loop Any help is appreciated [link] [comments] |
Posted: 18 Sep 2020 05:02 PM PDT As a side project, I'm trying to build an app using Android Studio that would emulate the functionality of a laptop touchpad via bluetooth. I've looked at some tutorials online and they've been helpful in understanding how two different mobile devices with the same app can communicate using bluetooth (ex. same chat apps on different phones) but I've been struggling to understand how a mobile device and PC can communicate the same information. I feel like im missing a critical piece info but I just don't know what. What type of resources should I be looking at to help understand how to implement it? [link] [comments] |
What does char - '0' mean? (C) Posted: 18 Sep 2020 11:33 AM PDT Question: If i have a char array variable in C. Let's call it "temp", "temp" is a char variable but contains 4 different integers. What happens when I do the operation "temp - '0'; ? [link] [comments] |
Posted: 18 Sep 2020 01:28 PM PDT Hello. I am writing a "MadLibs" code that allows someone to put in information which will change "???" into what the person typed. For the most part I have it written out so that someone can fill in the parts, only problem is I can't seem to figure out how to make what someone put in to change the "???" place markers. I am supposed to add in string slicing for five of these place markers. something like word = 'abcd' print(word[0:3]) which would print 'bc' I am not sure just how to replace the place markers so if anyone uses PyCharm and can help me please contact me. Thank you! [link] [comments] |
I have a strong feeling of age discrimination at job interviews in UK. Is that common? Posted: 18 Sep 2020 07:24 AM PDT Recently been through a few rounds of interviews with a few companies in London. My experience was that, all goes forward until the video call. Technically all goes fine on the interview. It's either a week excuse at the behaviour round or blatant unconscious bias from younger interviewers who are just out of uni. Have any of you mid 40s developers experienced this? [link] [comments] |
Posted: 18 Sep 2020 05:46 AM PDT |
Why architecture matters in terms of programming? Posted: 18 Sep 2020 03:05 AM PDT Architecture is the CPU's characteristics, how it solves hardware and physics problems at the lowest levels, correct? If yes, why do we need to care about architecture being a c++ developer? What the differences between ABIs of the same program compiled for arch1 and arch2? I mean that the machine code seems to be the same because source code doesn't change I can't really formulate the question and i feel that I have a gap in knowledge There are loads of architectures, which ones we need to support? Are there "popular"/"most used" architectures that must be targeted? Can I link executable with the library compiled for another architecture? I only know about x86, x64, and x86_64. What the difference between x86 and x86_64, because they both can run on CPU that support 64 bit addresses, why don't just compile application to target x86, because it has the same effect on 64-bit CPUs and 32-bit CPUs as x86_64 (Sorry if i get it wrong)? Are there some kind of "families" or groups of architectures (supporting each other in the range of their family/group) or they're all on their own? What books about that stuff you can recommend (For beginners/juniors)? [link] [comments] |
Can someone help me with flutter fcm integration for background messages? Posted: 18 Sep 2020 05:41 AM PDT |
Posted: 18 Sep 2020 03:32 AM PDT Hello there, i have a function that updates the database, the functions calls a function which calls a function which in the end gets data from an externall api. [link] [comments] |
Posted: 18 Sep 2020 10:26 AM PDT Hey, I have no idea if this is the right place to ask so if it's not please feel free to remove. I have absolutely no experience with programming and I don't think this even counts as programming but, here goes. I'm an English teacher and my students love playing a who am I style game. Before coronavirus this was super easy, I have loads of cards and pictures and things already prepared but now with the precautions we can't use them and they're really missing the games in the class. I'm looking to make something where I can input names of famous people and include a picture of them, that I can just press a button and it will select one at random. I use things like wheelspinners and random name selector tools quite a lot but I haven't been able to find something where I can do this with photos too. I also want to be able to save it, as opposed to having to constantly input the information everytime I use it. I want to be able to prepare it home and use it whenever. Can anybody help point me in the right direction of a programme or a website or something where I can create something like this? Or can you point me in the direction of a more appropriate sub where I can ask. Thank you in advance! [link] [comments] |
How would you represent a tree like structure in assembly language? Posted: 18 Sep 2020 10:13 AM PDT I would just like a basic idea about representing a tree structure in assembly code. I was thinking that recurssively calling functions makes the most sense, but im not sure if thats the best way or even if it would work. I can use some insight. [link] [comments] |
Is it easy to make an AI bot for a game that acts like human or has skills very similar to a human? Posted: 18 Sep 2020 03:26 AM PDT Also how much effort would it be to implement it to a game that already exist to make the AI of that game better, and would it be expensive? [link] [comments] |
Posted: 18 Sep 2020 04:46 AM PDT Hello guys, I have to create a flutter mobile app for a school project with my mates, which we have to put the app on the Google Play store, and I would like to use some Pokemon pictures. I know they are copyrighted, but I was wondering since it's for a school project, and since we're not planning to make people pay for it, could we use them anyway? I don't really know what the law says about it, but I figured someone here might help me. If this is not allowed, do you think the application could stay on the play store before being removed? [link] [comments] |
Posted: 18 Sep 2020 01:13 AM PDT What's the (second) best way to launch a Python process from C#? I've been seeing examples where the C# Interface just calls the Python script once for a result and ends the process. To use it again, it calls the Python script again, instantiating a class(again) and using its methods. Example: https://stackoverflow.com/questions/11779143/how-do-i-run-a-python-script-from-c Is there a way that C# spawns a Python Process and keeps it alive so I can call the Python method again and again without having to instantiate its class? I'll only end the Python process once a terminate signal is received from the C# Application. Of course the best way to do this would be to re-write my Python script into C# but i'm looking for a lazier and faster implementation since the library I made is pretty heavily dependent on Python ML libraries. [link] [comments] |
How would I classify strings into categories based on fuzzy matching? Posted: 18 Sep 2020 07:07 AM PDT I have 10 DNA sequences (which are strings made up of A,T,G,Cs) for genes from closely related bacterial species. I want to classify these sequences as follows. This is the output that I want to get: Sequences 1,3,6 are given a tag of Gene A Sequences 2,4,9 are of Gene B Sequence 5 is Gene C And so on based on similarity. How would I write a program that does this? The catch: Seq 1,3,6 (for Gene A) aren't 100% identical and as long as there is a 95% similarity it is acceptable. [link] [comments] |
You are subscribed to email updates from AskProgramming. To stop receiving these emails, you may unsubscribe now. | Email delivery powered by Google |
Google, 1600 Amphitheatre Parkway, Mountain View, CA 94043, United States |
No comments:
Post a Comment